bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug] close() returns "0" when closing unopened files


From: Seb
Subject: Re: [bug] close() returns "0" when closing unopened files
Date: Mon, 8 Dec 2008 19:03:25 +0100

Le Mon, 08 Dec 2008 05:51:21 +0200
Aharon Robbins <address@hidden> a écrit:

> > Oh! I forgot to notice that the returned values of close() are not 
> > documented
> > in the manual.
> 
> I'm sorry, but this is incorrect. In node  Close Files And Pipes it says:

My bad, you're absolutely right... I don't know how I missed the reference to
this node in the section "8.1.4 Input/Output Functions"... Sorry for the noise!

>       The POSIX standard is very vague; it says that @code{close}
>       returns zero on success and non-zero otherwise.  In general,
>       different implementations vary in what they report when closing
>       pipes; thus the return value cannot be used portably.
>       @value{DARKCORNER}
>       
> Thanks,

Thanks to you for pointing this portability issue. :)

++
Seb.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]