mpegts: Use av_free() to free memory allocated by av_strdup()

pull/80/head
Diego Biurrun 10 years ago
parent 5b220e1e19
commit 454697603e
  1. 6
      libavformat/mpegtsenc.c

@ -434,9 +434,9 @@ static MpegTSService *mpegts_add_service(MpegTSWrite *ts, int sid,
service->provider_name = av_strdup(provider_name);
service->name = av_strdup(name);
if (!service->provider_name || !service->name) {
free(service->provider_name);
free(service->name);
free(service);
av_free(service->provider_name);
av_free(service->name);
av_free(service);
return NULL;
}
dynarray_add(&ts->services, &ts->nb_services, service);

Loading…
Cancel
Save