Programación correcta. Como modificar /etc/passwd/ adecuadamente.
Roberto Jimeno
jimeno@pc6.politicas.unam.mx
Mon, 9 Feb 1998 15:59:14 -0600
> checate el comando getpwent y setpwent este te permite hacer lo que
> intentas
Del manual de getpwent:
>...
> The getpwent() function returns a pointer to a structure
> containing the broken out fields of a line from
> /etc/passwd. The first time it is called it returns the
> first entry; thereafter, it returns successive entries.
>
> The setpwent() function rewinds the file pointer to the
> beginning of the /etc/passwd file.
>
> The endpwent() function closes the /etc/passwd file.
>...
De modo que esas llamadas no sirven para modificar la tabla de
passwords. Solo son una manera correcta de leerla.
Gracias de todas formas.
--
-------------------------------------------------------------------------------
Roberto Jimeno. From The Cher-Speak Dictionary for the totally clueless:
loa.die (LO DE), n. 1. drug abusers. 2. acquaintances who you might party with but wouldn't want to be one of.