X-Recipient: archive-cygwin@delorie.com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:reply-to:message-id:to:subject
	:in-reply-to:references:mime-version:content-type
	:content-transfer-encoding; q=dns; s=default; b=Ektu7MGePFplBZxI
	vUoY13HU3cDWhQVyBEFlI3bmABM6a13/a+L9eHSj3vHtEmpafkC/wPTBBeId4M+0
	InnFJNYT1zYoHgsCpKr/fFDrQW0IimwHuFcMwd6OFmhSUzIkMseNuC3LQZ+376GO
	Mj7HgeBqHFK5xe0IDW1VQx7GMEo=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:reply-to:message-id:to:subject
	:in-reply-to:references:mime-version:content-type
	:content-transfer-encoding; s=default; bh=uxSn4CWi6wyc6j16aUegPs
	+pjKY=; b=hU/6RNpMRo/yZMQAXhIy4YxusVcvvGonobwVoZLZUk2E+lxQ0RVAPg
	MnqiPuniI+n6e7wqwpGRQmU33Fu6Zx3rEQ+W4LGOzVP3UQ/TQcJPPaXWcKtZyi3l
	3cm6Zb8/flJKYetVBbP/WP3ctiuY2RvRM42KH0hH0F5SeGqiQ45bE=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=4.1 required=5.0 tests=AWL,BAYES_50,FREEMAIL_FROM,KAM_THEBAT,SPF_SOFTFAIL autolearn=no version=3.3.2
X-HELO: smtpback.ht-systems.ru
Date: Fri, 7 Feb 2014 19:23:11 +0400
From: Andrey Repin <anrdaemon@yandex.ru>
Reply-To: Andrey Repin <cygwin@cygwin.com>
Message-ID: <18810323152.20140207192311@mtu-net.ru>
To: Steven Bardwell <sbardwell@lbmsys.com>, cygwin@cygwin.com
Subject: Re: using spawn functions to avoid fork() errors -- FIXED
In-Reply-To: <029e01cf2409$2cbc7e90$86357bb0$@lbmsys.com>
References: <029e01cf2409$2cbc7e90$86357bb0$@lbmsys.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-IsSubscribed: yes

Greetings, Steven Bardwell!

> I found  the problem that was causing the failure of child creation logic
> on the 64-bit install but not on the 32-bit version:

> in an effort to make the output from 'ps' more useful, my application was
> over-writing the contents of argv[1] in the main process. This trick works
> fine in many flavors of Unix (including Interix and Linux and 32-bit
> Cygwin).

CYGWIN=wincmdln
?

> However, in Cygwin 64-bit, it somehow corrupts things such that the
> child process created by fork() or spawnv() failed to load correctly. After
> removing that 'feature,' both spawnv() as well as the original fork() logic
> work without any problem.

Could still be NULL termination problem. If the strings you manipulating are
in UTF16, you need TWO \0 to terminate the string.


--
WBR,
Andrey Repin (anrdaemon@yandex.ru) 07.02.2014, <19:21>

Sorry for my terrible english...


--
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

