#include unistd.h
#include sys/types.h
#include stdio.h
Isn't #include pwd.h missing here?
Also check errno like Martin suggests. For this you need #include errno.h and
make sure you set errno=0 before you call getpwuid.
Cheers, Mark.
--
To unsubscribe from this list: send an email with
hi,
While printing the error it displaying No such file or directory.
What is the default file for getpwuid?...
Martin Mancuska wrote:
Did you try to print errno value ?
martin
2008/2/21, tomy [EMAIL PROTECTED]:
In my application
#include unistd.h
#include sys/types.h
#include
On Thu, Feb 21, 2008 at 7:53 PM, tomy [EMAIL PROTECTED] wrote:
hi,
While printing the error it displaying No such file or directory.
What is the default file for getpwuid?...
The man page says this :
NOTE
The user password database mostly refers to /etc/passwd.
However, with
Hi,
Thanks foe the information. I have created the file
/etc/nsswitch.conf and tried to run the same application, then perror is
printing success, but the password structure address remains 0. My
program and output is given below
#include unistd.h
#include sys/types.h
#include stdio.h