[dpdk-dev] [PATCH v5 2/5] pdump: check getenv return value
Mcnamara, John
john.mcnamara at intel.com
Sat Jun 25 00:50:43 CEST 2016
> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Reshma Pattan
> Sent: Friday, June 24, 2016 5:36 PM
> To: dev at dpdk.org
> Cc: Pattan, Reshma <reshma.pattan at intel.com>
> Subject: [dpdk-dev] [PATCH v5 2/5] pdump: check getenv return value
>
> inside pdump_get_socket_path(), getenv can return a NULL pointer if the
> match for SOCKET_PATH_HOME is not found in the environment. NULL check is
> added to return -1 immediately. Since pdump_get_socket_path() returns -1
> now, wherever this function is called there the return value is checked
> and error message is logged.
>
> Coverity issue 127344: return value check Coverity issue 127347: null
> pointer dereference
>
> Fixes: 278f945402c5 ("pdump: add new library for packet capture")
>
> Signed-off-by: Reshma Pattan <reshma.pattan at intel.com>
Acked-by: John McNamara <john.mcnamara at intel.com>
More information about the dev
mailing list