From patchwork Sun Sep 21 01:01:22 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dimitri John Ledkov X-Patchwork-Id: 4942901 Return-Path: X-Original-To: patchwork-linux-btrfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 5B26D9F32F for ; Sun, 21 Sep 2014 01:01:54 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 54BFF20142 for ; Sun, 21 Sep 2014 01:01:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 344AC2016C for ; Sun, 21 Sep 2014 01:01:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751860AbaIUBBp (ORCPT ); Sat, 20 Sep 2014 21:01:45 -0400 Received: from mail-wi0-f170.google.com ([209.85.212.170]:40622 "EHLO mail-wi0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751604AbaIUBBf (ORCPT ); Sat, 20 Sep 2014 21:01:35 -0400 Received: by mail-wi0-f170.google.com with SMTP id fb4so1185845wid.5 for ; Sat, 20 Sep 2014 18:01:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=surgut.co.uk; s=google; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=RHTBNnwpuvupWfvilIpgXHLUtp05kp0oJCr+knlO/G8=; b=K3qqkjYvWIp7hI5vDLZOBBsbcfkd89Xnx9cdsSbbE/IjmtwY6igQsySYgawiWbtR0e zGoOMbYzqHhAfcKZbFLyUQOUCxuxt1gJLBl/EZa0auGTblFUoIvupQkwXUttpwIx89RG R7cYS4sP4xgGkTjT3ZerheW0MqujPkcBLVYb0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=RHTBNnwpuvupWfvilIpgXHLUtp05kp0oJCr+knlO/G8=; b=gXJUcqFHPKvV8mCouYZjxc6ic8iTVhtqbWT1nMUw2oVTk7P7FbY07nPRPdNy0Uo/mj L6nmzNLTSeZ/e/FlVJ36naGGefn+vtVsF6IOIReocZv/6qhBj/322NhvZdnJHLZyJQJg 3MZDLMx5xWNPT1Dd+IN1ZYsUfTsYYJdBbPbh4QNhz0tS4b0JzuvxnS0JSLVRGo0vM/Dw /KQDNGb+1vx/WNkB430rXRNbm3xbFYFkiBk9bj2CTI0gWAbbsy1svxmCNwsQOab3GU5U pXk52kcjLM7FAFQujjkDpHBMrCAva+c6a4fS8QLOg5B+JykgTLgckyI61WCbmv0rhmJt IBXw== X-Gm-Message-State: ALoCoQmY/9+0Q1GgDpvXrp5EwXAtwZDg8dQ1iqjd8wwRu/FdYhKuREePdI3STIx4iTRpgKmcNx4m X-Received: by 10.180.149.130 with SMTP id ua2mr5991606wib.68.1411261294551; Sat, 20 Sep 2014 18:01:34 -0700 (PDT) Received: from localhost (cpc1-lewi13-2-0-cust98.2-4.cable.virginm.net. [86.14.120.99]) by mx.google.com with ESMTPSA id f3sm7028168wiz.18.2014.09.20.18.01.33 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 20 Sep 2014 18:01:33 -0700 (PDT) From: Dimitri John Ledkov To: linux-btrfs@vger.kernel.org Cc: Dimitri John Ledkov Subject: [PATCH 4/4] Default to acting like fsck. Date: Sun, 21 Sep 2014 02:01:22 +0100 Message-Id: <1411261282-26831-4-git-send-email-xnox@debian.org> X-Mailer: git-send-email 2.1.0.rc1 In-Reply-To: <1411261282-26831-1-git-send-email-xnox@debian.org> References: <1411261282-26831-1-git-send-email-xnox@debian.org> Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,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 Inspect arguments, if we are not called as btrfs, then assume we are called to act like fsck. Bug-Debian: http://bugs.debian.org/712078 Signed-off-by: Dimitri John Ledkov --- btrfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/btrfs.c b/btrfs.c index e83349c..e8a87ac 100644 --- a/btrfs.c +++ b/btrfs.c @@ -222,7 +222,7 @@ int main(int argc, char **argv) else bname = argv[0]; - if (!strcmp(bname, "btrfsck")) { + if (strcmp(bname, "btrfs") != 0) { argv[0] = "check"; } else { argc--;