From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=36800 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OK3Kx-0005BD-Qg for qemu-devel@nongnu.org; Thu, 03 Jun 2010 01:51:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OK3Ks-0008Kf-If for qemu-devel@nongnu.org; Thu, 03 Jun 2010 01:51:27 -0400 Received: from mail.codesourcery.com ([38.113.113.100]:35448) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OK3Ks-0008KT-Ao for qemu-devel@nongnu.org; Thu, 03 Jun 2010 01:51:22 -0400 From: Paul Brook Subject: Re: [Qemu-devel] [PATCH 2/3] qemu-thread: add cleanup_push() and cleanup_pop() Date: Thu, 3 Jun 2010 06:50:38 +0100 References: <1275118686-15649-1-git-send-email-corentincj@iksaif.net> <1275118686-15649-3-git-send-email-corentincj@iksaif.net> In-Reply-To: <1275118686-15649-3-git-send-email-corentincj@iksaif.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201006030650.38903.paul@codesourcery.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Corentin Chary , Anthony Liguori , Adam Litke , Alexander Graf , Gautham R Shenoy > From pthread man: > > These functions manipulate the calling thread's stack of > thread-cancellation clean-up handlers. A clean-up handler is > a function that is automatically executed when a thread is canceled > [...] it might, for example, unlock a mutex so that it becomes > available to other threads in the process. Do we really need to use thread cancellation? It's one of those features that makes me extremely nervous. Especially in C code where people generally aren't expecting exceptions to be thrown. Paul