On Thu, 28 Jun 2007, Erich Dollansky wrote:
> > According to Erich Dollansky on 6/26/2007 6:57 AM:
> >>if (stat ("/usr/X11R6/share/doc/lesstif-0.94.4/html/Lessdox", &Stat)
>
> is is right that the link is pointing to itself resulting in an endless
> loop?
No, it points to its parent directory
Hi,
Eric Blake wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to Erich Dollansky on 6/26/2007 6:57 AM:
if (stat ("/usr/X11R6/share/doc/lesstif-0.94.4/html/Lessdox", &Stat)
== 0)
{
printf ("Mode: %lX\n", (unsigned long) Stat.st_mode);
if (S_ISDIR (Stat.st_mode)
Eric Blake <[EMAIL PROTECTED]> writes:
> Matthew Woehlke users.sourceforge.net> writes:
>
>> >> "If the named file is a symbolic link, the stat() function shall
>> >> continue pathname resolution using the contents of the symbolic
>> >> link, and shall return information pertaining to the resulti
Matthew Woehlke users.sourceforge.net> writes:
> >> "If the named file is a symbolic link, the stat() function shall
> >> continue pathname resolution using the contents of the symbolic
> >> link, and shall return information pertaining to the resulting file
> >> if the file exists."
> >
> > Thi
David Kastrup wrote:
Eric Blake <[EMAIL PROTECTED]> writes:
PCYMTNQREAIYR
"If the named file is a symbolic link, the stat() function shall
continue pathname resolution using the contents of the symbolic
link, and shall return information pertaining to the resu
Eric Blake <[EMAIL PROTECTED]> writes:
> David Kastrup gnu.org> writes:
>
>> >> fstat, yes. But shouldn't stat be able to report S_ISLNK on a broken
>> >> link?
>> >
>> > No. It must fail with ENOENT.
>> > http://www.opengroup.org/onlinepubs/009695399/functions/stat.html
>>
>> No information t
David Kastrup gnu.org> writes:
> >> fstat, yes. But shouldn't stat be able to report S_ISLNK on a broken
> >> link?
> >
> > No. It must fail with ENOENT.
> > http://www.opengroup.org/onlinepubs/009695399/functions/stat.html
>
> No information there. "component of a path" has nothing to do wit
Eric Blake <[EMAIL PROTECTED]> writes:
> According to David Kastrup on 6/26/2007 7:10 AM:
>>
>> fstat, yes. But shouldn't stat be able to report S_ISLNK on a broken
>> link?
>
> No. It must fail with ENOENT.
> http://www.opengroup.org/onlinepubs/009695399/functions/stat.html
No information the
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to David Kastrup on 6/26/2007 7:10 AM:
>
> fstat, yes. But shouldn't stat be able to report S_ISLNK on a broken
> link?
No. It must fail with ENOENT.
http://www.opengroup.org/onlinepubs/009695399/functions/stat.html
- --
Don't work too h
Hi,
Eric Blake wrote:
-BEGIN PGP SIGNED MESSAGE-
Why is Lessdox not recognised as a link here?
Because your program asked about what the link pointed to, and not about
the link itself. The command line 'stat' uses lstat(), which is probably
what you want your program to do. And thi
Eric Blake <[EMAIL PROTECTED]> writes:
> According to Erich Dollansky on 6/26/2007 6:57 AM:
>>if (stat ("/usr/X11R6/share/doc/lesstif-0.94.4/html/Lessdox", &Stat)
>> == 0)
>>{
>> printf ("Mode: %lX\n", (unsigned long) Stat.st_mode);
>> if (S_ISDIR (Stat.st_mode))
>> pr
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to Erich Dollansky on 6/26/2007 6:57 AM:
>if (stat ("/usr/X11R6/share/doc/lesstif-0.94.4/html/Lessdox", &Stat)
> == 0)
>{
> printf ("Mode: %lX\n", (unsigned long) Stat.st_mode);
> if (S_ISDIR (Stat.st_mode))
> pri
Hi,
Eric Blake wrote:
If it were truly C++, you would have also showed the include files and
preprocessor macros that you used. If you want help on this issue,
provide a COMPILABLE example, and preferably one that is not so masked by
macros that it looks more like pascal than C++.
here we ar
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to Erich Dollansky on 6/26/2007 4:00 AM:
>>> When I run this little C++ program:
>>>
>>> PRIVATE VOID StatLessdox (VOID)
>>> BEGIN
...
>> This is NOT C++. Not without some obscure header included before the
>> source.
>>
> this is why I menti
Hi,
Václav Haisman wrote:
Erich Dollansky wrote:
[...]
When I run this little C++ program:
PRIVATE VOID StatLessdox (VOID)
BEGIN
struct stat Stat;
IF (stat ("/usr/X11R6/share/doc/lesstif-0.94.4/html/Lessdox", &Stat)
== 0) THEN
printf ("Mode: %lX\n", (unsigned long) Stat.st_m
Erich Dollansky wrote:
[...]
>
> When I run this little C++ program:
>
> PRIVATE VOID StatLessdox (VOID)
> BEGIN
>struct stat Stat;
>
>IF (stat ("/usr/X11R6/share/doc/lesstif-0.94.4/html/Lessdox", &Stat)
> == 0) THEN
> printf ("Mode: %lX\n", (unsigned long) Stat.st_mode);
>
16 matches
Mail list logo