well, I get the error if using cmd /c but not calling the batch file directly
don't use cmd /c and it will work
Thanks a lot! I could verify that, what you said, is true (though it only helps partially here, because in our application, we receive the commands to be executed from an outside source, and we can't control how they are created - but this is a different matter).
However, I don't feel that the explanation> you provided, is really correct to explain the case, for the following reason:
A batch file can't be run "by itself" - it always needs a CMD.EXE (or a compatible command interpreter) to run it; so, even if I pass the batchfile name directly, Perl (or Windows?) must, under the hood, spawn cmd.exe somewhere, in order to execute the batch file. Thus I don't think it has to do with whether or not CMD is used (it always is), but somewhat in the way system is implemented, manages to add the incorrect double quote in certain cases...
--
Ronald Fischer <ynnor@mm.st>
| [reply] [Watch: Dir/Any] [d/l] |
I can't tell, are you asking me something?
| [reply] [Watch: Dir/Any] |
are you asking me something?
No, not asking, just a comment to your (helpful) response. BTW, I think that the posting given by tye explains the behavour I am seeing.
--
Ronald Fischer <ynnor@mm.st>
| [reply] [Watch: Dir/Any] [d/l] |