Mail Archives: djgpp-workers/1999/06/23/01:21:12
DJ Delorie wrote:
>
> Comments?
Hmm... glibc just does:
struct qelem
{
struct qelem *q_forw;
struct qelem *q_back;
char q_data[1];
};
and dispenses with the typedef entirely.
It probably doesn't matter which we do. After all, the bug at hand
seems to have been present since 2.00 (according to cvs log)... goes to
show how much people use it :)
> ------- Start of forwarded message -------
> Sender: house AT usq DOT edu DOT au
> Date: Wed, 23 Jun 1999 00:17:31 +0000
> From: Ron House <house AT usq DOT edu DOT au>
> To: dj AT delorie DOT com
> Subject: DJGPP's search.h
> Content-Type: text/plain; charset=us-ascii
>
> To DJ Delorie
>
> Hi, thank you for putting out such an excellent system as DJGPP.
>
> I have found one bug. The file search.h says:
>
> struct qelem {
> struct qelem *q_forw;
> struct qelem *q_back;
> char q_data[0];
> } qelem;
>
> This produces linkage errors because it creates an actual variable
> called qelem in every file it is included in. I believe the line should
> read:
>
> typedef struct qelem {
> struct qelem *q_forw;
> struct qelem *q_back;
> char q_data[0];
> } qelem;
>
> I have altered my copy and it works fine.
>
> Thanks again,
> - --
> Ron House house AT usq DOT edu DOT au
>
> The evils of each age always seem self-evidently right at the time.
> ------- End of forwarded message -------
--
Nate Eldredge
nate AT cartsys DOT com
- Raw text -