From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f50.google.com (mail-wm0-f50.google.com [74.125.82.50]) by dpdk.org (Postfix) with ESMTP id 669295A35 for ; Mon, 13 Jun 2016 22:04:20 +0200 (CEST) Received: by mail-wm0-f50.google.com with SMTP id v199so92965987wmv.0 for ; Mon, 13 Jun 2016 13:04:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:user-agent:in-reply-to :references:mime-version:content-transfer-encoding; bh=/ye47E9Vr9EN25H/qgeBdOwF7klzxvC4nB0ItJqm1HY=; b=v2jFzWzUBa9At1dlL+yWin3YujVTK/Bz1Yooyp9PwUvhssA6MZAPIRCW6iIAaCCyYQ 3/1CBvFVYGa5qFHAcs7drBVs4bQzol2eRl23dC4v91HSi9DB8WeN4vnf+Un8TLUb+FTI Q3r4vy/1Gq10ZpMuMuv3FwBnvTFAhuOKPyGCwEUrYA7Vskq2xe7JoHUh+j36uDxH8AWi IOOOG2bGKHb28LcAAWE0eFeuVMPzDsz9Ge6xkKxtvIo3I6iWE/Ty+09ClUQug1wRGWb2 wgY0O1XyW6Q2wNuehjcq7yZN0ev/L8mJDSx7KoWvOgbMEbTUNcdHRR76iKuIXAdS7KFV 9jrA== 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:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=/ye47E9Vr9EN25H/qgeBdOwF7klzxvC4nB0ItJqm1HY=; b=gacjJbjnmseakHecfLzhz1CGwJelKfCcykmtnlNf1w4jn9K54pJnaLX2V7OByWphtg LGwIE4Vn/iiTW7M0SHjUpr1/05XMyz5M2AUjUYZV+3yioxB+hkxvlmIzB9kkAAV9MHpc bHyAM1J40FVjWLj7alov59ml3UAXCsNpoKlOsBHIYQ5ID7eVy6k+DCYRD7wE5DKviSMa n5jlyzdqcmW2JtClLWQhBJhntXyPDoTunhJ8M7DXbUFHyI3SbqYzBV7so/nIUeW9HWCa H338qNqxGUtXNoK9DNhCE/+lr9vgFTTo9RSB4LZXOW81j3GLGiN0+Y78IrnFee6Ta3ut sHcw== X-Gm-Message-State: ALyK8tLcTI4yFrIPZE/LzzGp5fSJfyW4161T9Q/JTXUiGkQXLXezFe30ZUFGHLp/UiP2aau+ X-Received: by 10.194.97.41 with SMTP id dx9mr2675309wjb.60.1465848260191; Mon, 13 Jun 2016 13:04:20 -0700 (PDT) Received: from xps13.localnet (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id e8sm378445wma.2.2016.06.13.13.04.18 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 13 Jun 2016 13:04:19 -0700 (PDT) From: Thomas Monjalon To: Tomasz Kulasek Cc: dev@dpdk.org, declan.doherty@intel.com, arkadiuszx.kusztal@intel.com Date: Mon, 13 Jun 2016 22:04:18 +0200 Message-ID: <4121599.adsh2vQa8a@xps13> User-Agent: KMail/4.14.10 (Linux/4.5.4-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <1465470872-2652-1-git-send-email-tomaszx.kulasek@intel.com> References: <1465470872-2652-1-git-send-email-tomaszx.kulasek@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Subject: Re: [dpdk-dev] [PATCH] app/test: fix array overflow warning with gcc 4.5 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Jun 2016 20:04:20 -0000 2016-06-09 13:14, Tomasz Kulasek: > DPDK/app/test/test_cryptodev.c: In function =E2=80=98create_snow3g_ci= pher_operation > _oop.clone.15=E2=80=99: DPDK/x86_64-native-linuxapp-gcc/include/rte_m= emcpy.h:796:14 > error: array subscript is above array bounds. >=20 > In test_cryptodev.c: > 2429=09rte_memcpy(sym_op->cipher.iv.data, iv, iv_len); >=20 > When iv_len is declared as 'unsigned int', rte_memcpy evaluates code = for > buffer size bigger than 255, but while 'iv' array is 64 bytes long, i= t > causes 'above array bounds' warning in gcc 4.5 and breaks compilation= . >=20 > Using uint8_t as a size of copied block prevents to evaluate in rte_m= emcpy > code for length bigger than 255, causing the problem. >=20 > The root of this issue and solution is the same as for commit 2c007ea= 10616 > ("app/test: fix array overflow warning with gcc 4.5") >=20 > Fixes: 9727af14b032 ("app/test: add out-of-place symmetric crypto > operations") >=20 > Signed-off-by: Tomasz Kulasek Applied, thanks