I run into a strange problem while using sed from a cmd.exe shell.
The problem is not sed specific and the following lines demonstrate it with /bin/echo.
The following mini program also demonstrates that it comes from the cygwin dll. -- slashtest.c -- #include <stdio.h> int main(int argc, char *argv[]) { printf("Arg1:%s:\n",argv[1]); return 0; } -- slashtest.c end --
Compile it with "gcc slashtest.c -o slashtest_cyg.exe" and "gcc -mno-cygwin slashtest.c -o slashtest_w32.exe" and try the following from a cmd.exe:
C:\cygwin\bin>\cygwin\home\quetschke\slashtest_w32.exe '\\\' Arg1:'\\\': _nothing done for a native binary, the quotes stay_
C:\cygwin\bin>\cygwin\home\quetschke\slashtest_cyg.exe '\\\' Arg1:\': _Hmm, one \ escaped and one ' escaped, quotes vanish if not escaped._
C:\cygwin\bin>\cygwin\home\quetschke\slashtest_cyg.exe \\\ Arg1:\\\: _Nothing special for a non-quoted string._
What is the deeper plan for this functionality?
Volker
-- PGP/GPG key (ID: 0x9F8A785D) available from wwwkeys.de.pgp.net key-fingerprint 550D F17E B082 A3E9 F913 9E53 3D35 C9BA 9F8A 785D
signature.asc
Description: OpenPGP digital signature