Mail Archives: djgpp-workers/2002/09/30/16:51:05
Hello.
Eli Zaretskii wrote:
>
> On Sun, 29 Sep 2002, Richard Dawe wrote:
[snip]
> > bash-2.04$ grep __canonicalize_path `find ../../../../include -name '*.h'`
> > bash-2.04$ grep __canonicalize_path `find ../.. -name '*.h'`
> >
> > Where should it be?
>
> If it should be in a public header, it's probably unistd.h.
>
> But I'm not sure we should put it into a public header, since it's an
> internal function. So either an internal header (local to the directory
> where fixpath.c and realpath.c live) or even just a prototype in
> fixpath.c and realpath.c would be okay, I think.
How about <sys/stat.h>? That's where _fixpath is declared. Below is a diff
that works for me.
Also, I guess __canonicalize_path should be documented.
Bye, Rich =]
--
Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ]
Index: include/sys/stat.h
===================================================================
RCS file: /cvs/djgpp/djgpp/include/sys/stat.h,v
retrieving revision 1.5
diff -p -u -3 -r1.5 stat.h
--- include/sys/stat.h 1 Dec 2001 20:18:59 -0000 1.5
+++ include/sys/stat.h 30 Sep 2002 20:50:03 -0000
@@ -80,6 +80,7 @@ mode_t umask(mode_t _cmask);
#define S_IFLABEL 0x5000
#define S_ISLABEL(m) (((m) & 0xf000) == 0x5000)
+char * __canonicalize_path(const char *, char *, size_t);
void _fixpath(const char *, char *);
unsigned short _get_magic(const char *, int);
int _is_executable(const char *, int, const char *);
- Raw text -