Jiasheng Jiang (HE12025-08-08): > I found that after the success of avio_alloc_context(), buffer is > assigned to rtp_ctx->pb->buffer and will be freed in whip_deinit(). > Therefore, I think moving av_freep() after end would cause a double > free.
Indeed, you are right, I had not checked that. With your change, if somebody adds an extra operation that might fail between allocating the buffer and using it in the avio context. It might be better to free the buffer at the end and set it to NULL if avio_alloc_context() succeeds to avoid the double free, but that is very minor. So no objection to the patch, just take half a second considering my suggestion. Regards, -- Nicolas George _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".