Thread: username to uid

  1. #1
    Obsessed with C chrismiceli's Avatar
    Join Date
    Jan 2003

    username to uid

    Given a username, is there an easy way to convert this to a uid in c/c++. I would hope not to have to look at /etc/passwd?
    Help populate a c/c++ help irc channel
    server: irc://
    channel: #c

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    The edge of the known universe
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. getpwnam_r returns wrong uid.
    By stevfletchcom in forum C Programming
    Replies: 5
    Last Post: 10-22-2008, 04:59 PM
  2. Getting the user's local username
    By Datamike in forum C Programming
    Replies: 8
    Last Post: 11-26-2005, 06:00 PM
  3. username collection
    By algi in forum C++ Programming
    Replies: 3
    Last Post: 01-22-2005, 02:20 PM
  4. username to uid mapping
    By rotis23 in forum C Programming
    Replies: 1
    Last Post: 10-30-2002, 04:17 AM
  5. getting username from Windows NT
    By Flucas in forum Windows Programming
    Replies: 1
    Last Post: 10-29-2001, 07:39 PM