From patchwork Wed Jul 19 20:35:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Biggers X-Patchwork-Id: 9853199 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 65889602BD for ; Wed, 19 Jul 2017 20:36:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4CC7728687 for ; Wed, 19 Jul 2017 20:36:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 41A8C286E5; Wed, 19 Jul 2017 20:36:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EB9AB28687 for ; Wed, 19 Jul 2017 20:36:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755997AbdGSUgU (ORCPT ); Wed, 19 Jul 2017 16:36:20 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:36448 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755210AbdGSUgT (ORCPT ); Wed, 19 Jul 2017 16:36:19 -0400 Received: by mail-pf0-f196.google.com with SMTP id a11so783544pfj.3 for ; Wed, 19 Jul 2017 13:36:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=E7D4FoFgALAtqs3yRh7UkltynY45wJkEdsRF8pnQ6HQ=; b=a8eU8digZQFFgdxrg3Y1WcWufyJTlZOnfBlcSLizBp5BJWrVqDwNnKsReq4jEcL97J ZZHyEG+S3S+BeMExoMVyttfV7uk10PQW3xHujX3ID0rQ6BbAl/n4dwxyGcABIxyU8ixf lwesZ3xjYxS9H+i66pMXG67e3PvcnPLOhaNTKx7Dlohf+UIn5NWPqwqab5OvkcshvJuN BvZ8sn1n2dYyK3WkGSecCSuJFdQn5QxhgRyMQuQwfvohc3MthfXQozt6+EKSZg+u2SXe 6HsnauuqAVfq1QEu8bydC3ZOq0S0FAWqpgSiACVKAklwy0zoRhdLp7NyxYrz7RGSgBCi OgRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=E7D4FoFgALAtqs3yRh7UkltynY45wJkEdsRF8pnQ6HQ=; b=qrwuzrV2c5M31m0BrkfW5ImqOJMtfedfMwC7ll69+6fUQfHIQTogaKCpItk1+6nbxY Z9sEJ8ZRala4s+FbXP1W57mUeH8M8pgGq5W15JtDg0C8MoBFFZF2fugUq1UP7fBqw1KB z47vhWDblzE3IWTlRuEI2Pvk4S7sLjOBg4Dtdo+BMbmZS5pC8iFoJx/Fscto8bCqDDSp x+xjNI8/s+0uojiDup2UI3/xwUd8KF81wvtDf9jEHc9hMGSGA69dbnc0pRXmNX9xU+MS It4CEc2ZX4XNxeYoA2y808q+KfxxTE7El6f0Iif0yZzgWy/2PVXNeVhRX/Eo+GVnv00/ ji+Q== X-Gm-Message-State: AIVw111jHM61+EOy3L2ymlm0nZ/2dM1WeQAXQbxGj95QkAUmI38kvguq SCo03VEP2xeDcDrxvj4= X-Received: by 10.99.160.80 with SMTP id u16mr1357937pgn.26.1500496579125; Wed, 19 Jul 2017 13:36:19 -0700 (PDT) Received: from ebiggers-linuxstation.kir.corp.google.com ([100.66.174.81]) by smtp.gmail.com with ESMTPSA id c27sm1171795pfe.154.2017.07.19.13.36.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 19 Jul 2017 13:36:18 -0700 (PDT) From: Eric Biggers To: fstests@vger.kernel.org Cc: Eric Biggers Subject: [PATCH] generic/421: stop test from hanging on buggy kernels Date: Wed, 19 Jul 2017 13:35:51 -0700 Message-Id: <20170719203551.126851-1-ebiggers3@gmail.com> X-Mailer: git-send-email 2.14.0.rc0.284.gd933b75aa4-goog Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Eric Biggers On some buggy kernels, the 'find' command in generic/421 encounters a "Permission denied" error when trying to search $dir, so it doesn't find the file it's supposed to. This causes 'cat' to read from stdin, hanging the test. Quote the argument to cat to make the test fail right away rather than hanging. Signed-off-by: Eric Biggers Reviewed-by: Carlos Maiolino --- tests/generic/421 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/generic/421 b/tests/generic/421 index 1b2f66f9..9ab48d47 100755 --- a/tests/generic/421 +++ b/tests/generic/421 @@ -98,7 +98,7 @@ keyid=$(_revoke_encryption_key $keydesc) # ciphertext on key revocation. Therefore, the name of the file we're opening # here may be in either plaintext or ciphertext depending on the kernel version, # and ciphertext names are unpredictable anyway, so just use 'find' to find it. -cat $(find $dir -type f) > /dev/null +cat "$(find $dir -type f)" > /dev/null # Wait for readers to exit touch $tmp.done