From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.devel Subject: Re: [PATCH 4/5] [mingw]: Delete existing target file before attempting rename. Date: Thu, 16 Jun 2011 23:45:48 +0200 Message-ID: <87fwn9fo1f.fsf@pobox.com> References: <1297784103-18322-1-git-send-email-janneke-list@xs4all.nl> <1297784103-18322-5-git-send-email-janneke-list@xs4all.nl> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1308260800 25503 80.91.229.12 (16 Jun 2011 21:46:40 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 16 Jun 2011 21:46:40 +0000 (UTC) Cc: guile-devel@gnu.org To: Jan Nieuwenhuizen Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Thu Jun 16 23:46:35 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QXKOY-0002bR-Vq for guile-devel@m.gmane.org; Thu, 16 Jun 2011 23:46:35 +0200 Original-Received: from localhost ([::1]:40413 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QXKOX-0007tc-VV for guile-devel@m.gmane.org; Thu, 16 Jun 2011 17:46:34 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:51903) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QXKNx-0007sd-5S for guile-devel@gnu.org; Thu, 16 Jun 2011 17:45:59 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QXKNu-0003rl-Va for guile-devel@gnu.org; Thu, 16 Jun 2011 17:45:56 -0400 Original-Received: from a-pb-sasl-sd.pobox.com ([64.74.157.62]:40093 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QXKNu-0003r4-G3 for guile-devel@gnu.org; Thu, 16 Jun 2011 17:45:54 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 5A03055BB; Thu, 16 Jun 2011 17:48:03 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=Bmze0PH0oa93QWW34U2F7IMNURY=; b=ULFJSW IHpQYALBo8OqW9bobrwi1W1V9B+IkZ/9KWEmrekMXroZuW26HLefImAkmWQQxp4u oiak7JAND4SzqcK1AyNsHrF7ZCR2S0HaprkQG8Gu0kFTDRvZMN43JQhIsnujnG9v V3G2xRrIIRoDvsRjZu3Zp357VALz+mtc2epvs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=mSe7zaA8LC1mWKQQSXkoe8jrxHCAvADs jgUtQhOTPIHgLQFJKsizAQxbezVOMl9QY4IxPZKgbMVI4OJKgMlQpy5vMJhcNHMv +b21UVeYWv1RpYJtD+Oby1zNszE2WG4NQGoU4g8GWRkxZoVSaw5ArlSviHP8hjQk A1h89XMvYWw= Original-Received: from a-pb-sasl-sd.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 51D4B55BA; Thu, 16 Jun 2011 17:48:03 -0400 (EDT) Original-Received: from badger (unknown [90.164.198.39]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTPSA id 9B0E755B9; Thu, 16 Jun 2011 17:48:02 -0400 (EDT) In-Reply-To: (Andy Wingo's message of "Sun, 01 May 2011 13:40:38 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-Pobox-Relay-ID: 4F6B0ACC-9862-11E0-92D6-5875C023C68D-02397024!a-pb-sasl-sd.pobox.com X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 64.74.157.62 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:12574 Archived-At: Hi Jan, On Sun 01 May 2011 13:40, Andy Wingo writes: > On Tue 15 Feb 2011 16:35, Jan Nieuwenhuizen writes: > >> From: Jan Nieuwenhuizen >> >> 2011-02-15 Jan Nieuwenhuizen >> >> * libguile/filesys.c [MINGW32] (my_rename): Add implementation >> that deletes target if it exists. Fixes rename behaviour. > > This patch has the obvious race condition. Why does the `rename' > library routine not work on Win32? The man page says > > CONFORMING TO > 4.3BSD, C89, C99, POSIX.1-2001. > > so I am surprised about this behavior. C99 actually doesn't specify what happens if the destination file exists. I have added the `rename' gnulib module, which should fix this particular issue (modulo canonicalize-lgpl, of course). Andy -- http://wingolog.org/