From patchwork Thu Sep 24 06:13:04 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "S. Fricke" X-Patchwork-Id: 7253931 Return-Path: X-Original-To: patchwork-linux-btrfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id C1307BEEC1 for ; Thu, 24 Sep 2015 06:18:25 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0480F20938 for ; Thu, 24 Sep 2015 06:18:25 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CF7742083A for ; Thu, 24 Sep 2015 06:18:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756356AbbIXGSU (ORCPT ); Thu, 24 Sep 2015 02:18:20 -0400 Received: from mail.data-modul.de ([212.184.205.171]:2603 "EHLO mail2.data-modul.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753206AbbIXGSS (ORCPT ); Thu, 24 Sep 2015 02:18:18 -0400 Received: from mail2.data-modul.de (unknown [192.168.99.33]) by mail2.data-modul.de (Postfix) with ESMTPS; Thu, 24 Sep 2015 08:13:08 +0200 (CEST) Received: from (unknown [192.168.100.11]) by mail2.data-modul.de with smtp (TLS: TLSv1/SSLv3,128bits,AES128-SHA) id 23a9_2e2c_be2be832_6284_11e5_bfe5_001e67036358; Thu, 24 Sep 2015 08:23:16 +0200 Received: from [192.168.100.63] (helo=sfrdevelbox.emb.data-modul.com) by demuc-sgit001.data-modul.com with esmtp (Exim 4.80) (envelope-from ) id 1ZezmF-0004wF-7e; Thu, 24 Sep 2015 08:13:07 +0200 Received: from sfr by sfrdevelbox.emb.data-modul.com with local (Exim 4.86) (envelope-from ) id 1ZezmE-0002CF-Vs; Thu, 24 Sep 2015 08:13:07 +0200 From: Silvio Fricke To: linux-btrfs@vger.kernel.org Cc: Silvio Fricke Subject: [PATCH 1/2] btrfs-progs: tasks info->id is a pthread_t and should not set to -1 Date: Thu, 24 Sep 2015 08:13:04 +0200 Message-Id: <7773bc3eb2de3b4a5be3ac1ae255331b93fe410f.1443074502.git.silvio.fricke@gmail.com> X-Mailer: git-send-email 2.5.3 In-Reply-To: References: In-Reply-To: References: Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, FREEMAIL_FROM,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Silvio Fricke --- task-utils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/task-utils.c b/task-utils.c index 58f5195..a4017ff 100644 --- a/task-utils.c +++ b/task-utils.c @@ -51,7 +51,7 @@ int task_start(struct task_info *info) info->private_data); if (ret) - info->id = -1; + info->id = 0; return ret; } @@ -64,7 +64,7 @@ void task_stop(struct task_info *info) if (info->id > 0) { pthread_cancel(info->id); pthread_join(info->id, NULL); - info->id = -1; + info->id = 0; } if (info->periodic.timer_fd) {