[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Reminder: $EDITOR with spaces?

From: Zack Weinberg <zack_at_codesourcery.com>
Date: 2002-04-28 23:50:55 CEST

On Sun, Apr 28, 2002 at 10:48:51PM +0200, Daniel Stenberg wrote:

> system() isn't portable, and it isn't exactly the safest function in
> the world.

Portability is a red herring. The function is guaranteed to exist by
the C standard. Portability of the *argument* (i.e. the value of
$EDITOR) is the responsibility of the user.

IMO safety is also a red herring -- as someone else said downthread,
the user can _already_ set $EDITOR to any value and have svn execute a
program based on that.

One remaining concern is quoting the filename argument. However, as I
understand it, $EDITOR is invoked only to generate log messages with,
which means Subversion controls the filename and can simply avoid
using shell metacharacters there.

zw

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Apr 28 23:51:58 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.