From owner-freebsd-current@FreeBSD.ORG Mon Sep 19 05:53:09 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3040E106566B; Mon, 19 Sep 2011 05:53:09 +0000 (UTC) (envelope-from alexz@visp.ru) Received: from mail.visp.ru (srv1.visp.ru [91.215.204.2]) by mx1.freebsd.org (Postfix) with ESMTP id DB4EA8FC0A; Mon, 19 Sep 2011 05:53:08 +0000 (UTC) Received: from 91-215-205-255.static.visp.ru ([91.215.205.255] helo=zagrebin) by mail.visp.ru with esmtp (Exim 4.72 (FreeBSD)) (envelope-from ) id 1R5Wmw-00017Y-IZ; Mon, 19 Sep 2011 09:53:06 +0400 From: "Alexander Zagrebin" To: "'Adrian Chadd'" References: <20110908221356.Horde.MFEsZ6Qd9PdOaSIEaid2X_A@avocado.salatschuessel.net><4E692F87.5010708@sentex.net><20110909073305.Horde.oi-EGaQd9PdOaaURAsTRVJk@avocado.salatschuessel.net><4E6A076D.7040309@wintek.com> In-Reply-To: Date: Mon, 19 Sep 2011 09:53:06 +0400 Keywords: freebsd-current Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 X-MimeOLE: Produced By Microsoft MimeOLE V6.1.7601.17514 Thread-Index: Acx163zkFzEMLOvqTXWMvAOpW2xp4gAozYkg Cc: freebsd-current@freebsd.org Subject: RE: cvsup broken on amd64? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Sep 2011 05:53:09 -0000 Hi! > So I've taken a look at the csup source. > > The problem here is the updater thread setting the "closed" state > (fixups_closed()) before calling updater_batch() again to handle > fixups. > > Checking for size != 0 at that point may not be valid at the list size > may actually be 0 for a short period of time. > > What about this patch: > > Index: updater.c > =================================================================== > --- updater.c (revision 224905) > +++ updater.c (working copy) > @@ -240,9 +240,9 @@ > * Make sure to close the fixups even in case of an error, > * so that the lister thread doesn't block indefinitely. > */ > - fixups_close(up->config->fixups); > if (!error) > error = updater_batch(up, 1); > + fixups_close(up->config->fixups); > switch (error) { > case UPDATER_ERR_PROTO: > xasprintf(&args->errmsg, "Updater failed: > Protocol error"); I've tried this patch. Now csup "hangs" before handling fixups. So there is no message "Applying fixups..." at all. -- Alexander Zagrebin