From patchwork Mon Apr 4 12:11:00 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Milard X-Patchwork-Id: 64983 Delivered-To: patch@linaro.org Received: by 10.112.199.169 with SMTP id jl9csp1121679lbc; Mon, 4 Apr 2016 04:11:52 -0700 (PDT) X-Received: by 10.140.20.39 with SMTP id 36mr38730008qgi.15.1459768312555; Mon, 04 Apr 2016 04:11:52 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id o34si21873854qge.94.2016.04.04.04.11.51; Mon, 04 Apr 2016 04:11:52 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 9FA8F616ED; Mon, 4 Apr 2016 11:11:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id CA4BA61653; Mon, 4 Apr 2016 11:11:47 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 4B29E6164A; Mon, 4 Apr 2016 11:11:43 +0000 (UTC) Received: from mail-lb0-f174.google.com (mail-lb0-f174.google.com [209.85.217.174]) by lists.linaro.org (Postfix) with ESMTPS id 3B64C6164A for ; Mon, 4 Apr 2016 11:11:41 +0000 (UTC) Received: by mail-lb0-f174.google.com with SMTP id bc4so155009093lbc.2 for ; Mon, 04 Apr 2016 04:11:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=jgUBjH2WYQF5tst3L/M/9xedNxQfCplQ8cbQcyvsfGo=; b=fw1rrv+2Pn+vxmgatJ6BcuCRMHJ4wLpVRyoF7xcZqOcOzcFKr8iotuhM5gG9I2ukWS WfBdHnUtyAmXVc32TfPJxbpIJUJ0GXo2Y4t1dWmBslZGhWquNyYoD8qGehID0BKg3cvp tsMyNEMjOeMZhYzjwu+6C8ZlyUAj8prU3U3MKUxfMj4NXBaLkjJCAudnCfnP5+XMEHev JXZj34q49WS00xVnpXwfkVPceN/UFjvqtefWyf7vbZwi0x36nYi+E1L2mx8MpVs9bJHZ Dd5P0K3WYFjxGL8gdBCqJ1U81gT896/d6qnbln1PyJ6U8aeQFAYBHjhXhWC0FjH1kEj+ Fxlw== X-Gm-Message-State: AD7BkJLKo8aQQRNaLvn/9+GuuraRCh7XTHj+T74Qv8Mun+ha8rx3bwgqjG/wkMVo7chrRaeWYrc= X-Received: by 10.112.160.35 with SMTP id xh3mr6298870lbb.86.1459768299734; Mon, 04 Apr 2016 04:11:39 -0700 (PDT) Received: from erachmi-ericsson.ki.sw.ericsson.se (c-83-233-90-46.cust.bredband2.com. [83.233.90.46]) by smtp.gmail.com with ESMTPSA id sv1sm1251663lbb.26.2016.04.04.04.11.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 04 Apr 2016 04:11:38 -0700 (PDT) From: Christophe Milard To: anders.roxell@linaro.org, mike.holmes@linaro.org, bill.fischofer@linaro.org Date: Mon, 4 Apr 2016 14:11:00 +0200 Message-Id: <1459771860-8584-1-git-send-email-christophe.milard@linaro.org> X-Mailer: git-send-email 2.1.4 X-Topics: patch Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [PATCH] linux-generic: test: shmem: string size fix X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Fixes: https://bugs.linaro.org/show_bug.cgi?id=2149 (CID 159392) Signed-off-by: Christophe Milard Reviewed-by: Mike Holmes --- platform/linux-generic/test/shmem/shmem_linux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/linux-generic/test/shmem/shmem_linux.c b/platform/linux-generic/test/shmem/shmem_linux.c index 12266cc..00318b8 100644 --- a/platform/linux-generic/test/shmem/shmem_linux.c +++ b/platform/linux-generic/test/shmem/shmem_linux.c @@ -100,7 +100,7 @@ int main(int argc __attribute__((unused)), char *argv[]) test_shared_linux_data_t *addr; /* odp app is in the same directory as this file: */ - strncpy(prg_name, argv[0], PATH_MAX); + strncpy(prg_name, argv[0], PATH_MAX - 1); sprintf(odp_name, "%s/%s", dirname(prg_name), ODP_APP_NAME); /* start the ODP application: */