Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Andrew Haley <aph@redhat.com>
To: Mark Kettenis <mark.kettenis@xs4all.nl>
Cc: gcc-patches@gcc.gnu.org, binutils@sourceware.org, gdb@sourceware.org
Subject: Re: [PATCH/libiberty] Add missing <sys/types.h> in unlink-if-ordinary.c
Date: Sat, 26 Mar 2005 14:27:00 -0000	[thread overview]
Message-ID: <16965.28989.543273.976317@cuddles.cambridge.redhat.com> (raw)
In-Reply-To: <200503261421.j2QEL6ll019253@elgar.sibelius.xs4all.nl>

Mark Kettenis writes:
 > One really shouldn't include <sys/stat.h> without <sys/types.h> on
 > BSD-derived systems.  On most modern BSD's it is brought in by
 > <unistd.h> but vax-dec-ultrix4.0 doesn't have one, so things break.
 > The attached patch fixes that.
 > 

You must wrap this in #ifdef HAVE_SYS_TYPES_H

Andrew.


 > 
 > Index: ChangeLog
 > from  Mark Kettenis  <kettenis@gnu.org>
 > 
 > 	* unlink-if-ordinary.c: Include <sys/types.h>.
 > 
 > Index: unlink-if-ordinary.c
 > ===================================================================
 > RCS file: /cvs/src/src/libiberty/unlink-if-ordinary.c,v
 > retrieving revision 1.1
 > diff -u -p -r1.1 unlink-if-ordinary.c
 > --- unlink-if-ordinary.c 1 Mar 2005 14:33:00 -0000 1.1
 > +++ unlink-if-ordinary.c 26 Mar 2005 14:18:20 -0000
 > @@ -39,6 +39,8 @@ was made to unlink the file because it i
 >  #include "config.h"
 >  #endif
 >  
 > +#include <sys/types.h>
 > +
 >  #ifdef HAVE_UNISTD_H
 >  #include <unistd.h>
 >  #endif


  reply	other threads:[~2005-03-26 14:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-03-26 14:21 Mark Kettenis
2005-03-26 14:27 ` Andrew Haley [this message]
2005-03-26 14:38   ` Mark Kettenis
2005-03-28  2:08     ` DJ Delorie
2005-03-28  2:19       ` Ian Lance Taylor
2005-03-28  2:35         ` DJ Delorie
2005-03-28 14:43           ` Mark Kettenis
2005-03-28 17:17             ` DJ Delorie
2005-03-27 18:48 ` Ian Lance Taylor

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=16965.28989.543273.976317@cuddles.cambridge.redhat.com \
    --to=aph@redhat.com \
    --cc=binutils@sourceware.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=gdb@sourceware.org \
    --cc=mark.kettenis@xs4all.nl \
    /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