| delorie.com/archives/browse.cgi | search |
| X-Recipient: | archive-cygwin AT delorie DOT 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:to:subject:message-id:reply-to | |
| :references:mime-version:content-type:in-reply-to; q=dns; s= | |
| default; b=sf7ZGwJ2+JUShFIbf4Q5xtY9wwNSy2MRMfDb7Glba3549mioMsO4U | |
| Flvo7yjtf4Vspch81oYFQwPZ62y9RwVgy3x5nb2Md5z4ktfOJzW2/ygN82gZguRQ | |
| yWjhAKPBf0GZrv0WlxVwXcXA20AXhP7N7PRGqDVkoFGRLjRPgdO8sg= | |
| 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:to:subject:message-id:reply-to | |
| :references:mime-version:content-type:in-reply-to; s=default; | |
| bh=wRPqzHNQMWj3fVuiZwhZ7LBKab4=; b=pLS5FG7944jdR4Z58XSEBIascdwr | |
| VcSzsswi/d+/dcmPGCtKJdAMfO1Pqf5YH6mujwqcVy1ZXYTQoIbl+mlIv3Cfbb1n | |
| PpElbZFXdqAgNfhSB2BIzPl+6/kPT4cPCDtqMPNQqU181ToeHyc4qFuzqsNMT7AM | |
| cpJpr/Elh4sTRUo= | |
| 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 |
| Authentication-Results: | sourceware.org; auth=none |
| X-Virus-Found: | No |
| X-Spam-SWARE-Status: | No, score=-5.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 |
| X-HELO: | calimero.vinschen.de |
| Date: | Tue, 2 Dec 2014 14:48:03 +0100 |
| From: | Corinna Vinschen <corinna-cygwin AT cygwin DOT com> |
| To: | cygwin AT cygwin DOT com |
| Subject: | Re: Fatal error using flock |
| Message-ID: | <20141202134803.GW3810@calimero.vinschen.de> |
| Reply-To: | cygwin AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| References: | <CAFSgOmZQ2WCABJa0gdN_7A2PhE+8CguqjA7ZQ8xXcDdc7OnDWw AT mail DOT gmail DOT com> |
| MIME-Version: | 1.0 |
| In-Reply-To: | <CAFSgOmZQ2WCABJa0gdN_7A2PhE+8CguqjA7ZQ8xXcDdc7OnDWw@mail.gmail.com> |
| User-Agent: | Mutt/1.5.23 (2014-03-12) |
--9Za+rIOv72GXlfHR
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Dec 1 23:43, Kyle R. wrote:
> I've run into a problem with flock while doing some parallel scripting
> in bash (also seen in dash) on the latest 64-bit version of Cygwin
> running on Windows 8.1. In the attached simple test case, the code
> locks and unlocks a file in a loop. After the first iteration of the
> loop is completed, this error is thrown:
>=20
> 0 [main] flock 7008 C:\cygwin64\bin\flock.exe: *** fatal error -
> NtCreateEvent(lock): 0xC0000035
> ./test.sh: line 12: 7008 Hangup flock -x 5
Confirmed. I'll investigate.
> However, the problem doesn't occur if I comment out the "while true
> do" and "done" and call the script file from a while loop in another
> bash script.
This sounds like a problem with the parent process holding the event
object connected to the lock. This doesn't happen in the second case,
because the parent holding the lock disappeared as well.
> but the inner workings of the locking
> system is a bit beyond me.
Pity. When I created the locking code I added lots and lots of comments
in the hope that
a) other people would have a chance to understand how the code is
supposed to work and
b) *I* have a chance to understand how the code is supposed to work
after not looking at the code for a year or longer...
Corinna
--=20
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Maintainer cygwin AT cygwin DOT com
Red Hat
--9Za+rIOv72GXlfHR
Content-Type: application/pgp-signature
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
iQIcBAEBAgAGBQJUfcMTAAoJEPU2Bp2uRE+gNcAP/24QUD8pIBAKetbRpI7E2EJ3
yGtLm8E1g0x9HaRpA/sIHih09viAHlHeeOcf0p//1Ojv+VA+z8sJ0R655MSakAwL
l31yS1MEPvrT5lB0wilk966o9juJYmCgTY8ngpmGlJUjvpiRZBw69PAZ52wMWz2r
Y1Fvn3HlYayCCNoY5UT/1in0V/yNVCPqk1AB8InYbYp/CSPdVdJ92ZO0Uw7XBS+w
CQpkPY5/1hvYBcxy+ifpBg54uRMUJe4lt9FeVneDsN1zMWTuTe6m41CfRY/UacrY
XyElcYWoGluT+adjGdmrDWLrWs+Yu7Hp1dRAu9CunQZ5L+6RcT27qrcTWNm6IRdv
0d1kB0wCaqtDH6m3aJnMsxL9l3iVhNrvqO9dW0Oza0DCMq2pD7Hk47ZRnQ14iRjF
GJIcG7Na0MZ+4msOx8S3gJEu7+fWc/FYwADcWw8AI2flBajTNVAxvPuQ+rMB6pBi
lxWmNYAULF+YZFBtyrhFN53zgQ/AgBFayncAhnZRX7fEnMeucv30goMc2hb950jN
LcEZiGwDJTYBrH8Et9xnb+eWStX05dyvvO/4izFHUOjJR/PwOB4YQS//ng7/KV+3
t/yVh+tihdjps2XrfXIDr/QNlmnKyjpN9gFpXlOAXXWM97F+BNE8lwrgfb/xCH05
sm4qCPfG+2TeRso3sL8M
=InfA
-----END PGP SIGNATURE-----
--9Za+rIOv72GXlfHR--
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |