[Issue 12114] buildNormalizedPath shouldn't normalize current path to empty string

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Feb 8 18:13:35 PST 2014


https://d.puremagic.com/issues/show_bug.cgi?id=12114


Vladimir Panteleev <thecybershadow at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |thecybershadow at gmail.com


--- Comment #1 from Vladimir Panteleev <thecybershadow at gmail.com> 2014-02-09 04:13:33 EET ---
(In reply to comment #0)
> 2. To reduce the chances of accidental bugs like this:
> auto from = buildNormalizedPath(...);
> executeShell("cp "~from~ " target"); // Oops, the "from" argument might be
> missing!

For the record and as an aside, this is poor practice. escapeShellCommand
should be used to build the command line, or (for this example) even better,
execute instead of executeShell.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list