Stefan Monnier <[EMAIL PROTECTED]> writes:
> I *am* sure about quotes. E.g. if
>
> %f
>
> is replaced by a file name such as
>
> a"; rm -rf ~/.;"
>
> you may even get a nasty surprise.
True, that would surprise me a lot...
So, you suggest making the option a list of strings instead of one
string? I think you will have to give me an example, because I cannot
see how that would make any difference to using one string, more than
to complicate things for the user (instead of having to configure one
option string, there would be several). To avoid quotes and other
"bad" characters in the arguments we would need to quote them in some
way, right? So couldn't the same be done to %f? Something like this:
(setq command
(format-spec
tumme-cmd-create-temp-image-options
(list
(cons ?p tumme-cmd-create-temp-image-program)
(cons ?x size-x)
(cons ?y size-y)
(cons ?f (tumme-quote-bad-characters file))
(cons ?t (tumme-quote-bad-characters new-file)))))
/Mathias
_______________________________________________
emacs-pretest-bug mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug