Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp3102903ybg; Sun, 20 Oct 2019 06:51:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqyi/LSq6uuwTvNLdMOzRHRRBo0QX94g6erlMmZCxTrozQ5pM/J8QvBmbKwoHcIt66+Pktyz X-Received: by 2002:a17:907:10dc:: with SMTP id rv28mr17426676ejb.7.1571579481563; Sun, 20 Oct 2019 06:51:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571579481; cv=none; d=google.com; s=arc-20160816; b=ZNZNyWtFjFBt2/of6caPFMVjfhMVXzN5nDH/IQyI20ag5wo5VzNHfX60hkatVUmm1J gzMWOr6w8A4utxSPxPDwdGpo0TIGCjt9CiMN02LgTEeMw2VufuFsMzV6W0ViMk6CFSAE WgnGsvDvv+dZRgrkasnEq1jck99Mg37MuCvOsBlO3KjfBUZBw0cAGLAUALFJvbfMU4uP naagi4Ar18qTUI3nNbHaLTO0yEHrKRQ6gK9RM+zk/T6IsWiLoaOVxA6dh3ykR7ZvAHdm Y3K3tf3ouQoODaQFtexKaqOk1XkGqjsojm9ROCkrtjKAOgfMvYBrlYP1nCCAzZXSSv1K WDyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=9efnMENP/VJVkPlRfJzxJpy/Qvr8rPVnQoIn87fOb8E=; b=nplnSbqZ7N/9CSA8qVz14SCig6gBa4UF2FFK2ZmTafVu11bP6vMLCaIdhrQYygr9PF BR2QOPShB8gHfcQ7WxXfW7UeVP3cD1T+hTwz0v99GiwmZRGnZHakcVX209kKrBi3O904 IydSpbiAwXjxV8tf5QC0VS/r7W6feyEZLeTRP6CB7Rbv4YUc+wXw+H0R0PhhdPVMPc6W azxHxqZbQV75TeqNJUYWUxTRMvmx87sQKsbNAoS4DavymbBoONdAHFLJfjrenPfd5y3M R07YssTGo48C/Zcia+dXG/OAxOZRoWdQA2T/jdvRFDAW66rwmdyCkUzH8a6/L/Jeeg3q HRYQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=L7j1pM2L; spf=pass (google.com: best guess record for domain of linux-nfs-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z2si798603edd.140.2019.10.20.06.50.42; Sun, 20 Oct 2019 06:51:21 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-nfs-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=L7j1pM2L; spf=pass (google.com: best guess record for domain of linux-nfs-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726301AbfJTNug (ORCPT + 99 others); Sun, 20 Oct 2019 09:50:36 -0400 Received: from mail-pf1-f193.google.com ([209.85.210.193]:46651 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726299AbfJTNug (ORCPT ); Sun, 20 Oct 2019 09:50:36 -0400 Received: by mail-pf1-f193.google.com with SMTP id q5so6637018pfg.13; Sun, 20 Oct 2019 06:50:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=9efnMENP/VJVkPlRfJzxJpy/Qvr8rPVnQoIn87fOb8E=; b=L7j1pM2LrLyr78v19iv75LxcO/y4D45ZfSOqxCCX36Dn2h5YoLYNmVWPK1FBI0Xk7i b3FJnGZd5S06xuf3M8LwTvR+jYodxY23AnnYV6Wp8Cndbls8MznvaMPrghuZDu570xaB +RC3iCM5xAZmtfnHOB63H7x281rz+BGv3fABEpO/mqHwzTYioJQkADpjgHUADYGGuMf7 y2ZUmc+nqRFljoK7NzJNG0Q+GtASyUwpXydCTVBC+KlUjNX6IoMGZwUWyx9exwsNTxhn K2K2taO6IBDsENi+CnjGEDE44KzunHDYTAwbvmzYtXJ2iaiRS7ltNdfJSzd+d0FbwXZJ R2qQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=9efnMENP/VJVkPlRfJzxJpy/Qvr8rPVnQoIn87fOb8E=; b=sFFLBAbfTVOFMeZdHgh/dfyRkPVPBoWRTWoVd06HfZnY7nck2+ZLUkysSW/DSaCI8i DuNzF+MDvEkSpKSf/pt8Mh4VhRNWWJH6Q4sbFuajSwGUtDHfNRmGCjLhyewP01E3m9gG hB2x5m4TYuKzb4g/Mwk8DgZGCmeJeXEszk7QT28ZoallA7KJc/XkGX5BZf2kdpFaLluH iVDfBG7jAyn1+Fn2rUJ7cYl/0HeGOria9UxIGDAFMdcrRMNYAwsV0WPcYt3HTDrUR67F iNr446VheqRDRXl21l4J4cNOCSUewTXBEEORvZUwIfM94ZjXHMoRCLVp7R//SOW+OzhQ XA+g== X-Gm-Message-State: APjAAAVxn5aXK/ya2EXE3LexbMVxiXIXdAQ8y9jFTLucHqNpntfkhjOJ sq6lD+wq+iKjLCS7gTpWXaI= X-Received: by 2002:a63:6f02:: with SMTP id k2mr20797283pgc.163.1571579435452; Sun, 20 Oct 2019 06:50:35 -0700 (PDT) Received: from localhost ([178.128.102.47]) by smtp.gmail.com with ESMTPSA id s18sm12335203pji.30.2019.10.20.06.50.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 20 Oct 2019 06:50:34 -0700 (PDT) Date: Sun, 20 Oct 2019 21:50:28 +0800 From: Eryu Guan To: schumaker.anna@gmail.com Cc: fstests@vger.kernel.org, linux-nfs@vger.kernel.org, Anna.Schumaker@netapp.com Subject: Re: [PATCH 2/2] generic: 448 shouldn't delete $BASE_TEST_FILE if it isn't set yet Message-ID: <20191020135028.GA2543@desktop> References: <20191018173343.303032-1-Anna.Schumaker@Netapp.com> <20191018173343.303032-2-Anna.Schumaker@Netapp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191018173343.303032-2-Anna.Schumaker@Netapp.com> User-Agent: Mutt/1.12.1 (2019-06-15) Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Fri, Oct 18, 2019 at 01:33:43PM -0400, schumaker.anna@gmail.com wrote: > From: Anna Schumaker > > NFS v4.2 supports SEEK_DATA and SEEK_HOLE, but earlier versions do not. > As a result, the test exits and runs the cleanup function without the > $BASE_TEST_FILE variable set and the shell expands it to "rm -f .*", > deleting all hidden files in the current directory. > > Signed-off-by: Anna Schumaker > --- > tests/generic/448 | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/tests/generic/448 b/tests/generic/448 > index dada499b..d6cdebbf 100755 > --- a/tests/generic/448 > +++ b/tests/generic/448 > @@ -17,7 +17,8 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 > > _cleanup() > { > - rm -f $tmp.* $BASE_TEST_FILE.* > + rm -f $tmp.* > + [ ! -z $BASE_TEST_FILE ] && rm -f $BASE_TEST_FILE.* > } I'd just define BASE_TEST_FILE before _cleanup (and did it on commit). Thanks for the fix! Eryu > > # get standard environment, filters and checks > -- > 2.23.0 >