tar bugfix patch n.347 (recoded, version 4)

Vladimir N. Oleynik dzo at simtreas.ru
Thu Dec 22 13:37:02 UTC 2005

Roberto and Rob,

>> Care to explain the comment?  Right now, we depend on exit() to clean 
>> up our memory most of the time.  The FEATURE_CLEAN_UP stuff is a 
>> debugging aid to find memory leaks in loops that might blow up into 
>> something significant with big data sets.  (We might later add 
>> infrastructure to allow busybox to not depend on a kernel with a 
>> working fork/exit, but that's 1.2 or later work and would require 
>> adding rather a lot of infrastructure that might best be done as a 
>> separate "fakefork.so" library (that wraps the fork() and exec() 
>> families, malloc(), free(), mmap(), mumap(), open(), close(), and 
>> probably a whole lot more...  Or perhaps fakefork belongs in uClibc?  
>> Who knows?)

My reall busybox router have script:

$ tar cf - /etc /bin/ /usr /home | ( cd /mnt/copy_here; tar xf - )

for save configuration.

Its make
- double shell to memory
- double tar to memory

We can`t change fork() to vfork() trivially, this applets use BSS
variables (prezeroed) and for vfork() is not separetelly.

>  http://www.erlenstar.demon.co.uk/unix/faq_2.html
>  which document are talking about zombies too and how to preventing they 
> happen. Solaris docs was read just because I worked on solaris hw but 
> actually I do not have any such hw.

This zombie have very small life. ;-)
After parent readed last pipe buffer, parrent exited also.
"Tar" is not a daemon server, using async sigchild handler is nonsense.
You can found true Unix documentation with typically example with fork()+pipe().


More information about the busybox mailing list