Selon Tito <[email protected]>:
> On Wednesday 26 January 2011 15:24:17 Gilles Espinasse wrote:
> > Selon Tito <[email protected]>:
> >
> > > Hi,
> > > in id.c maybe I've found a minor bug.
> > >
> > > } else if (n < 0) { /* error in get_groups() */
> > > - if (!ENABLE_DESKTOP)
> > > + if (ENABLE_DESKTOP)
> > > bb_error_msg_and_die("can't get groups");
> > > else
> > > return EXIT_FAILURE;
> > > }
> > >
> > >
> > > ciao,
> > > Tito
> >
> >
> > Another issue.
> >
> > Should really 'return EXIT_FAILURE' depend of ENABLE_DESKTOP?
> >
> >
> > Gilles
> >
>
> My idea was ENABLE_DESKTOP = bloat so verbose error message
> !ENABLE_DESKTOP= minimal so only return error to shell
>
> Maybe I'm overlooking something obvious?
> Ciao,
> Tito
>
>
I miss the _and_die part and think that was bad to have an exit status depending
of ENABLE_DESKTOP.
I don't know if size would be better or worse without the else but exit status
should remain inchanged.
A few lines above in print_common function, there is
if (option_mask32) {
if (ENABLE_DESKTOP)
bb_error_msg("unknown ID %u", id);
return EXIT_FAILURE;
}
which is a different way (no else, no _and_die) to have a similar handling (but
there in a function)
Gilles
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox