Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Blame | Last modification | View Log | Download | RSS feed

  1. /* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
  2. #include <pwd.h>
  3. #include <unistd.h>
  4.  
  5. static int count=0;
  6.  
  7. void
  8. setpwent(void)
  9. {
  10.   count=0;
  11. }
  12.  
  13. struct passwd *
  14. getpwent(void)
  15. {
  16.   if (count == 0)
  17.   {
  18.     count++;
  19.     return getpwuid(getuid());
  20.   }
  21.   return 0;
  22. }
  23.  
  24. void
  25. endpwent(void)
  26. {
  27.   count=0;
  28. }
  29.