From nobody Sun Feb 8 18:50:54 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1594398844; cv=none; d=zohomail.com; s=zohoarc; b=m2LSkRHx4fdhRVnUl/yUTUYZAJ553afg5y6QfJrOWiJfPH5HYALojxj/U391VqwsuiyV1DkZ5+v+knWNSU2Rr3Re6C+ZiB2qGVAzQFP3uNV9q2CZAJf6U3zzlk8uBiMwHn7InGmh/s76nGZ/Ljj1+5H/ZLiTc+LQ5rL04zIDZO4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1594398844; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=cvyzzuBWOhSh/D2b/DAr+rl5JnwWsbc2V629CLjsrqI=; b=QbnfGm6C9r01xHluJrlc93TddHJkGJ1rmyF8Wc30mSGY+kaHM5lV5peoMMe4Ohacb0sPYBZEUq/bLZqz7vWXKQH7gYot0oYtTuvnI3AZIt/XLSua1yhIMpiGi1Cnbh+saMVEZnY6/ZSvCFKH39WV8Lckvs7ttV7/JcqRN4bR2x4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1594398844442770.9735955546411; Fri, 10 Jul 2020 09:34:04 -0700 (PDT) Received: from localhost ([::1]:47946 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jtvyN-0005jJ-3L for importer@patchew.org; Fri, 10 Jul 2020 12:34:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47046) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jtvxO-00044s-10 for qemu-devel@nongnu.org; Fri, 10 Jul 2020 12:33:02 -0400 Received: from us-smtp-1.mimecast.com ([205.139.110.61]:57159 helo=us-smtp-delivery-1.mimecast.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1jtvxM-0007vh-G6 for qemu-devel@nongnu.org; Fri, 10 Jul 2020 12:33:01 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-198-krdl1TxwMjqcSqRuSs_jpw-1; Fri, 10 Jul 2020 12:32:58 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 17525107BEF5; Fri, 10 Jul 2020 16:32:57 +0000 (UTC) Received: from localhost (ovpn-113-127.ams2.redhat.com [10.36.113.127]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B050C17D82; Fri, 10 Jul 2020 16:32:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594398779; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cvyzzuBWOhSh/D2b/DAr+rl5JnwWsbc2V629CLjsrqI=; b=ijZh+43bbf/ZpAN2OwgJfF22XY+Wvn8C8KmC4wSrLx5A5yw6xUM/7lcB/AJ2Xgd33h8Eej 8hsau9TUF4fnxj8aN+w9kKUMIICztRssppgN0lHsTRJI1sWgGKzCQ7pvI8n+/brJ8vEavS R/mHv9suNdqvbhX0iVUjTr6bYdBCVZw= X-MC-Unique: krdl1TxwMjqcSqRuSs_jpw-1 From: Max Reitz To: qemu-block@nongnu.org Subject: [PATCH 1/2] iotests: Drop readarray from _do_filter_img_create Date: Fri, 10 Jul 2020 18:32:51 +0200 Message-Id: <20200710163253.381630-2-mreitz@redhat.com> In-Reply-To: <20200710163253.381630-1-mreitz@redhat.com> References: <20200710163253.381630-1-mreitz@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=205.139.110.61; envelope-from=mreitz@redhat.com; helo=us-smtp-delivery-1.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/07/09 22:08:55 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -40 X-Spam_score: -4.1 X-Spam_bar: ---- X-Spam_report: (-4.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Kevin Wolf , John Snow , qemu-devel@nongnu.org, Max Reitz Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Some systems where we run tests on do not have a 4.x bash, so they do not have readarray. While it looked a bit nicer than messing with `head` and `tail`, we do not really need it, so we might as well not use it. Reported-by: Claudio Fontana Signed-off-by: Max Reitz Reviewed-by: Eric Blake --- tests/qemu-iotests/common.filter | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/qemu-iotests/common.filter b/tests/qemu-iotests/common.f= ilter index 3833206327..345c3ca03e 100644 --- a/tests/qemu-iotests/common.filter +++ b/tests/qemu-iotests/common.filter @@ -138,13 +138,13 @@ _do_filter_img_create() # Split the line into the pre-options part ($filename_part, which # precedes ", fmt=3D") and the options part ($options, which starts # with "fmt=3D") - # (And just echo everything before the first "^Formatting") - readarray formatting_line < <($SED -e 's/, fmt=3D/\n/') + read formatting_line =20 - filename_part=3D${formatting_line[0]} - unset formatting_line[0] + # Split line at the first ", fmt=3D" + formatting_line=3D$(echo "$formatting_line" | $SED -e 's/, fmt=3D/\nfm= t=3D/') =20 - options=3D"fmt=3D${formatting_line[@]}" + filename_part=3D$(echo "$formatting_line" | head -n 1) + options=3D$(echo "$formatting_line" | tail -n +2) =20 # Set grep_data_file to '\|data_file' to keep it; make it empty # to drop it. --=20 2.26.2