This is the mail archive of the cygwin@sources.redhat.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Two snapshot bugs


> So 'getcwd (NULL, -1)' should return something but 'getcwd 
> (NULL, 0)', IMO,
> should not.
#include <stdio.h>
#include <unistd.h>
#include <errno.h>
int main()
{
   char *dir = getcwd(NULL, 0);
   perror("Error =");
   printf("getcwd=%s\n", dir);

}
 Sets EINVAL in Irix.
 Sets EINVAL in SunOS 5.6
 Looks like "getcwd" returns the right thing.  Should errno be set?

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]