This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug manual/16776] Endless loop in strtol example
- From: "mtk.manpages at gmail dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Wed, 30 Apr 2014 03:55:16 +0000
- Subject: [Bug manual/16776] Endless loop in strtol example
- Auto-submitted: auto-generated
- References: <bug-16776-131 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=16776
--- Comment #3 from Michael Kerrisk <mtk.manpages at gmail dot com> ---
(In reply to Olaf van der Spek from comment #2)
> Bugs in examples are bad, they *will* be copied into real code.
I'mquite agree.
But, Olaf, why not just provide a patch? Seems to me the solution is just an
API of the form:
int sum_ints_from_string(char * str, int &result)
which returns 0 on failure, 1 on success.
--
You are receiving this mail because:
You are on the CC list for the bug.