Bug 19486 - iconv(3) declaration does not match man page
iconv(3) declaration does not match man page
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: man-pages (Show other bugs)
7.0
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Trond Eivind Glomsrxd
Aaron Brown
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-10-20 15:48 EDT by Jesper Skov
Modified: 2007-04-18 12:29 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-10-24 04:48:45 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jesper Skov 2000-10-20 15:48:37 EDT
Man page sez it should be

       size_t iconv (iconv_t cd,
                     const char* * inbuf, size_t * inbytesleft,
                     char* * outbuf, size_t * outbytesleft);

while the iconv.h declaration is:

extern size_t iconv (iconv_t __cd, char **__restrict __inbuf,
                     size_t *__restrict __inbytesleft,
                     char **__restrict __outbuf,
                     size_t *__restrict __outbytesleft);

That is, missing const propery on inbuf. Judging from the semantics of
the function, I'd say it should be const like the man page suggests.

Jesper
Comment 1 Jakub Jelinek 2000-10-24 04:48:38 EDT
The man page is broken, the correct prototype is in glibc (and in its
texinfo documentation). The prototype has been mistakenly defined with
const char ** in the standards but that has been corrected since then.
Comment 2 Trond Eivind Glomsrxd 2000-10-24 14:58:59 EDT
Fixed in 1.31-2. Thanks

Note You need to log in before you can comment on or make changes to this bug.