From: Pedro Alves <pedro@codesourcery.com>
To: gdb-patches@sourceware.org, Eli Zaretskii <eliz@gnu.org>
Subject: Re: [RFA] Define EILSEQ if not defined by errno.h
Date: Sat, 11 Apr 2009 19:26:00 -0000 [thread overview]
Message-ID: <200904112026.46999.pedro@codesourcery.com> (raw)
In-Reply-To: <83zlennh8p.fsf@gnu.org>
On Saturday 11 April 2009 20:05:26, Eli Zaretskii wrote:
> Any objections to the following patch? DJGPP doesn't have EILSEQ
> defined in its errno.h.
No objections. AFAICS, this is what gnu libiconv does. EILSEQ can
also be defined in wchar.h, so as long as this is done after
including wchar.h, it is fine.
My first question when I read this, was if you had chosen ENOENT as
an arbitrary choice, and I was curious with what was libiconv doing
--- which made me have to go grep libiconv sources.
IMO, a comment mentioning that this is what GNU iconv does
would be good to spare such doubts for whoever reads this.
>
>
> 2009-04-11 Eli Zaretskii <eliz@gnu.org>
>
> * charset.c (EILSEQ): Define if not defined by errno.h.
>
> Index: gdb/charset.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/charset.c,v
> retrieving revision 1.19
> diff -u -r1.19 charset.c
> --- gdb/charset.c 25 Mar 2009 00:58:34 -0000 1.19
> +++ gdb/charset.c 11 Apr 2009 19:03:08 -0000
> @@ -89,6 +89,12 @@
> #undef ICONV_CONST
> #define ICONV_CONST const
>
> +/* Some systems, don't have EILSEQ. But don't define it as EINVAL,
> + because callers of `iconv' want to distinguish EINVAL and EILSEQ. */
> +#ifndef EILSEQ
> +#define EILSEQ ENOENT
> +#endif
> +
> iconv_t
> iconv_open (const char *to, const char *from)
> {
>
--
Pedro Alves
next prev parent reply other threads:[~2009-04-11 19:26 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-11 19:05 Eli Zaretskii
2009-04-11 19:26 ` Pedro Alves [this message]
2009-04-11 21:27 ` Eli Zaretskii
2009-04-13 16:54 ` Tom Tromey
2009-04-13 18:52 ` Eli Zaretskii
2009-04-13 18:58 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200904112026.46999.pedro@codesourcery.com \
--to=pedro@codesourcery.com \
--cc=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox