From patchwork Thu Nov 22 17:58:28 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Darrick J. Wong" X-Patchwork-Id: 10694631 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 292F513BB for ; Thu, 22 Nov 2018 17:58:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 210A42C15F for ; Thu, 22 Nov 2018 17:58:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 14B372C17C; Thu, 22 Nov 2018 17:58:45 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY 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 BA5CA2C15F for ; Thu, 22 Nov 2018 17:58:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2395544AbeKWEjK (ORCPT ); Thu, 22 Nov 2018 23:39:10 -0500 Received: from aserp2120.oracle.com ([141.146.126.78]:36778 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2395487AbeKWEjK (ORCPT ); Thu, 22 Nov 2018 23:39:10 -0500 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.22/8.16.0.22) with SMTP id wAMHsQeN105063; Thu, 22 Nov 2018 17:58:42 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : from : to : cc : date : message-id : in-reply-to : references : mime-version : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=T7foTYRqwU2BC+Gu+GdWGq1l/0aaLUeqgXjDrfnDUvc=; b=1avcOmrir4H5SpvhZ98NJXPVMAChKq2JoTUUJZZoLBj2k4mhLnlB3FacGksCvMXkX69x 4Vnvr9PV+D+VFxLePwaVdndhEzNKBjz+a/+iY30hdZapOOrGi6KX6GtEYKINDZNV0E1z ypjvwz2EdIqm7UaOz5PJwmxxrmqE67SaeRNeFpxQLgYIBaHSLnjRLxfNnpKqRunhB3Jw a1GUGZkg7IqsQsClGWZnaWyPRwsX4uw1zU6DvUQ7THcNOQJo+DyipXRMXXDpr8kQtRJB CMGP8/Be1Qe06CxKCG1WEHs3lsAlKow6ThWvMlE0B3+RrnWqJkAWtGaHBKCwxIJXAPND +Q== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp2120.oracle.com with ESMTP id 2ntaxqg11a-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 22 Nov 2018 17:58:42 +0000 Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id wAMHwZvF016505 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 22 Nov 2018 17:58:36 GMT Received: from abhmp0016.oracle.com (abhmp0016.oracle.com [141.146.116.22]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id wAMHwZFC024188; Thu, 22 Nov 2018 17:58:35 GMT Received: from localhost (/67.169.218.210) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 22 Nov 2018 09:58:35 -0800 Subject: [PATCH 01/12] fsstress: fix compiler warnings From: "Darrick J. Wong" To: guaneryu@gmail.com, darrick.wong@oracle.com Cc: linux-xfs@vger.kernel.org, fstests@vger.kernel.org Date: Thu, 22 Nov 2018 09:58:28 -0800 Message-ID: <154290950874.1218.16162093723366805081.stgit@magnolia> In-Reply-To: <154290950237.1218.9937108728673485814.stgit@magnolia> References: <154290950237.1218.9937108728673485814.stgit@magnolia> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9085 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=754 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1811220160 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Darrick J. Wong Fix all the gcc warnings in fsstress. Signed-off-by: Darrick J. Wong Reviewed-By: Allison Henderson --- ltp/fsstress.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ltp/fsstress.c b/ltp/fsstress.c index edbb3f2f..8d0734fc 100644 --- a/ltp/fsstress.c +++ b/ltp/fsstress.c @@ -499,7 +499,7 @@ int main(int argc, char **argv) exit(1); } if (logname) { - char path[PATH_MAX]; + char path[PATH_MAX + NAME_MAX + 1]; snprintf(path, sizeof(path), "%s/%s", rpath, logname); if (freopen(path, "a", stdout) == NULL) { perror("freopen logfile failed"); @@ -583,7 +583,7 @@ int main(int argc, char **argv) return 0; #endif if (logname) { - char path[PATH_MAX]; + char path[PATH_MAX + NAME_MAX + 2 + 11]; snprintf(path, sizeof(path), "%s/%s.%d", rpath, logname, i); if (freopen(path, "a", stdout) == NULL) {