[ovs-dev] [PATCH 1/1] vlog: fix memory leak in vlog_set_log_file() function

Ben Pfaff blp at ovn.org
Wed Oct 2 14:55:18 UTC 2019


On Wed, Oct 02, 2019 at 01:44:49PM +0200, Damijan Skvarc wrote:
> memory leak happens in case previously closed log file was reopened again,
> for example:
> 
> ovs-appctl vlog/close
> ovs-appctl vlog/reopen

Thanks.  I applied this to master.

I removed the 'if' here, since free(NULL) is a no-op:
> +    if (log_file_name) {
> +        free(log_file_name);
> +    }


More information about the dev mailing list