
FishMonger
Veteran
Oct 10, 2011, 6:52 PM
Post #4 of 5
(798 views)
|
|
Re: [Paveltc] Calling system() on Cygwin/Windows
[In reply to]
|
Can't Post
|
|
Windows not only supports but uses / forward slashes for the directory separator at the system level. It's cmd.exe that "doesn't or may not like" forward slashes. Here's a clear example where using forward slashes works.
C:\Users\Ron>cd c:/Windows c:\Windows> There are cases were you need to use quotes around the path/string, such as when calling some 3rd party executables, but Windows itself doesn't require them and when it does, you can escape them when passing the command to the system call. Instead of dancing around hypothetical assumptions, you should post concrete examples that you're having trouble with so that we can show you how to deal with the situation.
|