From patchwork Sat May 19 17:43:10 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 10412923 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 098F56032C for ; Sat, 19 May 2018 17:43:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DF91328676 for ; Sat, 19 May 2018 17:43:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D40E92867F; Sat, 19 May 2018 17:43:18 +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=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI, 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 30C8328676 for ; Sat, 19 May 2018 17:43:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752462AbeESRnR (ORCPT ); Sat, 19 May 2018 13:43:17 -0400 Received: from imap.thunk.org ([74.207.234.97]:55136 "EHLO imap.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752451AbeESRnQ (ORCPT ); Sat, 19 May 2018 13:43:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=thunk.org; s=ef5046eb; h=Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=0U8O3s9iqaFRmHLOozT32L/g18WQHuJVj0x1P298xSA=; b=F3lUT5r/Vkr+Ro8Tfb50g8Q2e9 kYNJtb6ESGId34M/mCpCUV/1UciQvOknguQDyUBWiMKV+UH2YyjKYPuXmypGN2zhV/rY57uw13hNX jFdUYORJ5wUOfb/2/vG/6SUsOcyatKAAsmwvfm8/K9glnQr07NbyQXOk7MDhTHtjodbE=; Received: from root (helo=callcc.thunk.org) by imap.thunk.org with local-esmtp (Exim 4.89) (envelope-from ) id 1fK5sw-0005xe-Tl; Sat, 19 May 2018 17:43:14 +0000 Received: by callcc.thunk.org (Postfix, from userid 15806) id C6DA57A5C7F; Sat, 19 May 2018 13:43:13 -0400 (EDT) From: Theodore Ts'o To: fstests@vger.kernel.org Cc: Theodore Ts'o Subject: [PATCH] report: make sure control charcters are encoded in xUnit report Date: Sat, 19 May 2018 13:43:10 -0400 Message-Id: <20180519174310.3511-1-tytso@mit.edu> X-Mailer: git-send-email 2.16.1.72.g5be1f00a9a X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@thunk.org X-SA-Exim-Scanned: No (on imap.thunk.org); SAEximRunCond expanded to false Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Control characters (such as backspace, used in progress reports by mkfs.ext4, for example) can make Python's XML parsers choke, claiming that it is an invalid XML document. Signed-off-by: Theodore Ts'o --- common/report | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/common/report b/common/report index ffa23719..a62d343e 100644 --- a/common/report +++ b/common/report @@ -27,11 +27,12 @@ REPORT_ENV_LIST="$REPORT_ENV_LIST OVL_WORK" encode_xml() { - sed -e 's/&/\&/g' \ - -e 's/>/\>/g' \ - -e 's//\>/g' \ + -e 's/