Mailinglist Archive: yast-devel (78 mails)
| < Previous | Next > |
Re: [yast-devel] Re: [yast-commit] r66316 - in /trunk/snapper: VERSION agent-snapper/src/SnapperAgent.cc agent-snapper/src/SnapperAgent.h package/yast2-snapper.changes src/Snapper.ycp src/dialogs.ycp
- From: Jiri Suchomel <jsuchome@xxxxxxx>
- Date: Mon, 10 Oct 2011 09:07:39 +0200
- Message-id: <201110100907.39873.jsuchome@suse.cz>
Dne Pá 7. října 2011 16:53:28 Ladislav Slezak napsal(a):
Good points. I actually do not see the need for Quoter there, but passing --
seems to be really good idea.
Jiri
--
Jiri Suchomel
SUSE LINUX, s.r.o. e-mail: jsuchome@xxxxxxx
Lihovarská 1060/12 tel: +420 284 028 960
190 00 Praha 9, Czech Republic http://www.suse.cz
--
To unsubscribe, e-mail: yast-devel+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: yast-devel+owner@xxxxxxxxxxxx
Similar problem, although very unlikely, if a file name contains an HTML
tag it would be wrongly displayed. Use String::EscapeTags().
- SCR::Execute (.target.bash, sformat ("/bin/cp -a '%1' '%2'", orig,
file)); + SCR::Execute (.target.bash, sformat ("/bin/cp -a '%1' '%2'",
orig, full_path));
String::Quote() should be also used here, '%1' helps when there is a space,
but doesn't help when the string contains ' (a single quote).
And if the command supports (cp does) we should use -- option to stop the
option processing. If %1 begins with -- it would be processed as an
option, in some cases this can completely change the meaning of the
command.
Good points. I actually do not see the need for Quoter there, but passing --
seems to be really good idea.
Jiri
--
Jiri Suchomel
SUSE LINUX, s.r.o. e-mail: jsuchome@xxxxxxx
Lihovarská 1060/12 tel: +420 284 028 960
190 00 Praha 9, Czech Republic http://www.suse.cz
--
To unsubscribe, e-mail: yast-devel+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: yast-devel+owner@xxxxxxxxxxxx
| < Previous | Next > |