> -----Original Message----- > From: Denys Vlasenko [mailto:[EMAIL PROTECTED] > Sent: den 19 april 2008 23:30 > To: Joakim Tjernlund > Cc: [email protected] > Subject: Re: [PATCH] start-stop-daemon: make --exec follow symlinks. > > On Saturday 19 April 2008 22:45, Joakim Tjernlund wrote: > > > Let me know if you see more problems, or have cleanups. > > > > I do, you haven't applied the patch to pid_is_cmd(). That > > part is still buggy(as I explained earlier), even in current svn. > > Now xmalloc_open_read_close will return NULL if open fails, > and this fixes the bug.
Nope, read what I wrote: "hmm, xmalloc_open_read_close do use xopen though, but even if this was fixed, it can die. The other users expects this too. It does not make sense to fail open/lseek/read and return a ptr with garbage in it. If you make sizep mandatory, it might make sense if you do *sizep =-1 in case of error." You cannot die due to I/O errors, nor return a NULL to start-stop-daemon. The function name itself implies this but doesn't do so. > There is also xmalloc_xopen_read_close now and it is used > where we want to die if open fails (in other applets, > not start_stop_daemon). > -- > vda _______________________________________________ busybox mailing list [email protected] http://busybox.net/cgi-bin/mailman/listinfo/busybox
