Bug 55077 - httpd.h: allow use of strtoul(2)
Summary: httpd.h: allow use of strtoul(2)
Status: CLOSED FIXED
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: Core (show other bugs)
Version: 2.5-HEAD
Hardware: PC Linux
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-07 17:05 UTC by Arno Töll
Modified: 2013-07-26 17:56 UTC (History)
0 users



Attachments
Allow use of strtoul (761 bytes, patch)
2013-06-07 17:05 UTC, Arno Töll
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Arno Töll 2013-06-07 17:05:12 UTC
Created attachment 30406 [details]
Allow use of strtoul

On behalf of a user spotting this on Debian, I'm forwarding you bug http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=711534. httpd.h defines in httpd.h

/** strtoul does not exist on sunos4. */
#ifdef strtoul
#undef strtoul
#endif
#define strtoul strtoul_is_not_a_portable_function_use_strtol_instead


I'm sure that's true for sunos4, but I don't see any harm to let third parties use strtoul if they wanted to. The statement is exaggerating as well.  strtoul is defined in POSIX-2001, BSD's stdlib.h, and many more - with the exception of sunos4 for sure, but that's obsolete for a decade at least.

That said, I have no strong opinion on it. Feel free to keep it, if you feel like, but I doubt this outweighs breaking any semi-recent C standard.
Comment 1 Stefan Fritsch 2013-06-09 08:23:01 UTC
trunk commit: r1491155
proposed for 2.4
Comment 2 Jeff Trawick 2013-07-26 17:56:25 UTC
in 2.4.6 release (r1494121)