Re: Get User Groups

From: jpd (read_the_sig_at_do.not.spam.it)
Date: 09/30/04


Date: Thu, 30 Sep 2004 15:09:47 +0000 (UTC)

On 2004-09-29, Kushal Agarwal <kushal.agarwal@gmail.com> wrote:
> I am wondering what is the system call to get all the groups a user
> belongs to. I need both the group ids and the group names. I need to
> make this call from a c++ module.

Use getgrent(3) to cycle through the groups file and and reconstruct
the list.

BTW, you're in the wrong group, and you're multiposting. Read up on
``netiquette'' as to what those are and why you should do neither.

-- 
  j p d (at) d s b (dot) t u d e l f t (dot) n l .


Relevant Pages

  • Re: Multiple Input Rectifiers
    ... Please, if your post truly belongs in two NGs, cross-post ... it rather than multiposting. ... relevant NGs into the 'Newsgroups:' header. ... > Is there such a thing of taking multiple AC signals and converting them to DC (similar to what a bridge rectifier ...
    (sci.electronics.design)
  • Re: Multiple Input Rectifier
    ... Please, if your post truly belongs in two NGs, cross-post ... it rather than multiposting. ... relevant NGs into the 'Newsgroups:' header. ... > Is there such a thing of taking multiple AC signals and converting them to DC (similar to what a bridge rectifier ...
    (sci.electronics.basics)
  • Re: Solaris 10 - How to update OS to latest build
    ... BTW, Solaris 10, 3/05 is the latest official release; ... /usr belongs to the O/S and might be replaced in whole or in part by an upgrade. ... /usr/local is a hangover from BSD and is not part of the SVr4 Unix standard. ...
    (comp.unix.solaris)
  • Re: Stockhausen MOMENTE - news
    ... BTW. ... can identify the piece it belongs to.)> ... I'll take Kontra-Punkte behind door number three. ...
    (rec.music.classical.contemporary)
  • Re: Vick Gets 23 Months In Prison
    ... Not if it belongs to them. ... He's completely loony on this issue, BTW. ... Name calling so soon? ...
    (rec.sport.football.college)