> IMO popen is a POSIX function, so it should also work on Windows.
I agree that it should work ;-)
However, it did not work on Windows 98. Win98 treats ' as part of the
command line parameters. (e.g. "dir 'c:\windows'" returns a "file not
found" error where "dir c:\windows" does not.)
> (is Windows POSIX compliant?
The word "compliant" seems to confuse Microsoft. ;-)
The 32-bit Windows (WinNT, Win9x, etc) subsystem is supposedly POSIX
The shell in Win95/98 is not even close to being POSIX compliant (it is
DOS command.com). Once the shell call works then it will still be a
nightmare to use filtering. There is no script processor, only batch
files and executables. Nothing more than basic (broken) pipes. The
bright side is that GNU BASH for Windows runs under the CygWin Unix
emulator and works around most of these limitations.
> NT should be...)
The WinNT shell (cmd.exe) seems to be reasonably POSIX compliant.
(Script support, decent pipes, etc.) Microsoft also ships Korn shell in
the Unix option pack.
I don't think this will be a problem on NT. However, I do not have any
way to test for sure.
> Perhaps there should be a "correction macro" or subroutine,
> which does a conversion or shell escaping of filenames for shells.
A macro is probably good enough. There are only 2 or 3 instances where
SWISH-E accesses a shell. I can't imagine many more instances where we
would want to add shell calls in the future.
Dave's Web - http://www.webaugur.com/dave/
Dave's Weather - http://www.webaugur.com/dave/wx
ICQ Universal Internet Number - 412039
E-Mail - email@example.com
Received on Mon Jun 19 10:59:09 2000