[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: new static uid/gid needed (ups)



On Wed, 25 Aug 1999, Ruud de Rooij wrote:

> Can't you determine the uid at run time with code similar to the following?
> 
>     struct passwd * passwd_entry;
>     uid_t           ups_uid;
> 
>     if (! (passwd_entry = getpwnam("ups"))) {
>         fprintf(stderr, "user id `ups' does not exist\n");
>         exit(EXIT_FAILURE);
>     }
>     ups_uid = passwd_entry->pw_uid;
> 
> It would make the program also more robust against changes in the uid 
> numbering done by the system administrator.

I'd have to ask upstream author, or patch it myself. Don't you consider
UPS to be worthy piece of hw to have statical ids as the rest does?

Is something wrong with static ids, apart from fact that it means more
work to someone? I think both solutions are legal, is there a policy or
just common sense to guide me?

-- 
jozef  :-)  
Hi! I'm a .signature virus! Copy me into your ~/.signature to help me spread!


Reply to: