On Tue, Jul 30, 2019 at 11:24 PM Andriy Gelman <[email protected]>
wrote:

> From: Andriy Gelman <[email protected]>
>
> ---
>  libavfilter/f_zmq.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/libavfilter/f_zmq.c b/libavfilter/f_zmq.c
> index 89da5bef06..744c721305 100644
> --- a/libavfilter/f_zmq.c
> +++ b/libavfilter/f_zmq.c
> @@ -139,7 +139,7 @@ static int recv_msg(AVFilterContext *ctx, char **buf,
> int *buf_size)
>          ret = AVERROR(ENOMEM);
>          goto end;
>      }
> -    memcpy(*buf, zmq_msg_data(&msg), *buf_size);
> +    memcpy(*buf, zmq_msg_data(&msg), *buf_size - 1);
>      (*buf)[*buf_size-1] = 0;
>
>  end:
> --
> 2.22.0
>

LGTM, I can not apply it, so I kindly ask other committers to apply it.
_______________________________________________
ffmpeg-devel mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".

Reply via email to