Re: [PATCH 3/3] chsh: Add libuser support

Karel Zak
2013-01-07T11:51:14Z

On Thu, Jan 03, 2013 at 11:34:11AM -0500, Miloslav Trmac wrote:
> > + memset(&val, 0, sizeof(val));
> > + g_value_init(&val, G_TYPE_STRING);
> > + g_value_set_string(&val, shell);
> > +
> > + lu_ent_clear(ent, LU_LOGINSHELL);
> > + lu_ent_add(ent, LU_LOGINSHELL, &val);
> If you don't mind depending on libuser >= 0.58, all of the above can be replaced with
> > lu_ent_set_string(ent, LU_LOGINSHELL, shell);
> and you can drop the "g_value_unset" calls as well.

It would be nice to drop g_* junk :-)

Karel

--
Karel Zak <kzak@redhat.com>