From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:40075) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TXsPA-0006y5-ND for qemu-devel@nongnu.org; Mon, 12 Nov 2012 06:42:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TXsP7-0007YX-Ic for qemu-devel@nongnu.org; Mon, 12 Nov 2012 06:42:16 -0500 Received: from mail-pb0-f45.google.com ([209.85.160.45]:52473) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TXsP7-0007YR-Ay for qemu-devel@nongnu.org; Mon, 12 Nov 2012 06:42:13 -0500 Received: by mail-pb0-f45.google.com with SMTP id mc8so1606532pbc.4 for ; Mon, 12 Nov 2012 03:42:12 -0800 (PST) Sender: Paolo Bonzini Message-ID: <50A0E08E.5010503@redhat.com> Date: Mon, 12 Nov 2012 12:42:06 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1350545426-23172-1-git-send-email-quintela@redhat.com> <1350545426-23172-5-git-send-email-quintela@redhat.com> In-Reply-To: <1350545426-23172-5-git-send-email-quintela@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 04/30] buffered_file: Move from using a timer to use a thread List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Juan Quintela Cc: qemu-devel@nongnu.org Il 18/10/2012 09:30, Juan Quintela ha scritto: > @@ -160,11 +162,8 @@ static int buffered_close(void *opaque) > if (ret >= 0) { > ret = ret2; > } > - qemu_del_timer(s->timer); > - qemu_free_timer(s->timer); > - g_free(s->buffer); > - g_free(s); > - > + ret = migrate_fd_close(s->migration_state); > + s->complete = true; > return ret; Just above these lines there is ret2 = migrate_fd_close(s->migration_state); I believe the second call to migrate_fd_close should be removed. Paolo