[ovs-dev] [PATCH] pcap-file: Fix memory leak in ovs_pcap_open()

Aaron Conole aconole at redhat.com
Wed Sep 1 13:21:21 UTC 2021


Yunjian Wang <wangyunjian at huawei.com> writes:

> In ovs_pcap_open(), we allocate memory for the 'p_file'
> structure but not released when fopen fails.
>
> Addresses-Coverity: ("Resource leak")
> Fixes: b6e840aed03e ("pcap-file: Add nanosecond resolution pcap support.")
> Signed-off-by: Yunjian Wang <wangyunjian at huawei.com>
> ---

Good catch.  Thanks.

Acked-by: Aaron Conole <aconole at redhat.com>



More information about the dev mailing list