[PATCH] mesg.c: make tty variable use only dynamic memory
Denys Vlasenko
vda.linux at googlemail.com
Tue Mar 22 05:52:49 UTC 2011
On Tuesday 22 March 2011 00:47, Tito wrote:
> attached as drop in replacement file a alternative version with:
> 1) better command line options checking (catches yx error)
> 2) size reduction
> function old new delta
> fchmod - 31 +31
> __fchmod - 31 +31
> bb_perror_nomsg_and_die - 9 +9
> mesg_main 174 158 -16
> chmod 31 - -31
> __chmod 31 - -31
> ------------------------------------------------------------------------------
> (add/remove: 4/2 grow/shrink: 0/1 up/down: 71/-78) Total: -7 bytes
> 3) better error messages
> 4) no dynamically allocated memory
>
> it is just a proof of concept and little tested but seems to work.
> If there is interest I can make a patch.
> Hints, critics and improvements are welcome.
Thanks, I used your idea while making USE_TTY_GROUP thing configurable.
--
vda
More information about the busybox
mailing list