delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-0.4 required=5.0 tests=AWL,BAYES_00,RCVD_NUMERIC_HELO,SPF_HELO_PASS,SPF_PASS |
X-Spam-Check-By: | sourceware.org |
To: | cygwin AT cygwin DOT com |
From: | "jojelino" <jojelino AT gmail DOT com> |
Subject: | cygwin passes argv with preserved (") quote. and it is undesired result. |
Date: | Thu, 31 Dec 2009 17:00:25 +0900 |
Lines: | 30 |
Message-ID: | <hhhlmo$68u$1@ger.gmane.org> |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
hi here is testcase to reproduce the problem #include <stdio.h> #include <assert.h> int main(int argc, char**argv) { printf("argv %s",argv[1]); open(argv[1],"r"); assert(fp); return 0; } build make ¤±.txt in directory. and run in cmd.exe type, a "¤±.txt" and it complains file can't be opened. and you can see argv[1] is passed with preserved quote (") although it is invoked in winshell it must be eliminted when it is transduced to cygwin environment. but when parent process is cygwin, it gives no complaint >strace a "¤±.txt" in result, is it designed to do so? (well i assume it bug.) if not, how this can be avoided?? -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |