From: Paul Jackson Date: Sun, 17 Apr 2005 01:00:55 GMT Subject: Re: [PATCH] show-diff shell safety Message-ID: <20050416180055.76cb8a25.pj@sgi.com> In-Reply-To: <7vbr8e44u1.fsf@assigned-by-dhcp.cox.net> Junio wrote: > The command line for running "diff" command is built without > taking shell metacharacters into account. Ack - you're right. One should avoid popen and system in all but personal hacking code. There are many ways, beyond just embedded shell redirection, to cause problems with these calls. One should directly code execve(), execv(), or execl(). Search for "popen system IFS PATH" -- I won't rest till it's the best ... Programmer, Linux Scalability Paul Jackson 1.650.933.1373, 1.925.600.0401