From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:44336) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iE3vr-0004h4-Vt for guix-patches@gnu.org; Sat, 28 Sep 2019 00:02:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iE3vp-0000St-Sb for guix-patches@gnu.org; Sat, 28 Sep 2019 00:02:07 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40078) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iE3vp-0000QN-BM for guix-patches@gnu.org; Sat, 28 Sep 2019 00:02:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iE3vm-0007nZ-E5 for guix-patches@gnu.org; Sat, 28 Sep 2019 00:02:02 -0400 Subject: bug#37510: [PATCH 1/1] compile: Fix race condition on completion progress. Resent-To: guix-patches@gnu.org Resent-Message-ID: Date: Sat, 28 Sep 2019 00:01:08 -0400 (EDT) From: Eric Bavier Message-ID: <1740315284.38306958.1569643268369.JavaMail.zimbra@centurylink.net> In-Reply-To: <87tv8yixmb.fsf@gnu.org> References: <20190925020706.6034-1-ericbavier@centurylink.net> <87pnjnpfsz.fsf@gnu.org> <58295170.37303056.1569505365844.JavaMail.zimbra@centurylink.net> <87tv8yixmb.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 37510-done@debbugs.gnu.org ----- On Sep 26, 2019, at 3:57 PM, Ludovic Court=C3=A8s ludo@gnu.org wrote: > Eric Bavier skribis: >=20 >>>> +++ b/guix/build/compile.scm >>>> @@ -173,7 +173,8 @@ files are for HOST, a GNU triplet such as >>>> \"x86_64-linux-gnu\"." >>>> =20 >>>> (define (build file) >>>> (with-mutex progress-lock >>>> - (report-compilation file total completed)) >>>> + (report-compilation file total completed) >>>> + (set! completed (+ 1 completed))) >>>=20 >>> Here =E2=80=98completed=E2=80=99 is incremented before the thing is eve= n started. >> >> Maybe a more generic name like "progress" would be appropriate? >=20 > Yes, probably! Ok, pushed with a rename to "progress" in commit 21391f8c83. --=20 `~Eric