emotion: free channels only if there's channel to free
No need to free channels if there's no channels to be freed. By: Leandro Dorileo <dorileo@profusion.mobi> SVN revision: 75741
This commit is contained in:
parent
6335870b45
commit
1375052f40
|
@ -362,7 +362,7 @@ _audio_channels_free(Emotion_Generic_Video *ev)
|
|||
int i;
|
||||
for (i = 0; i < ev->audio_channels_count; i++)
|
||||
eina_stringshare_del(ev->audio_channels[i].name);
|
||||
free(ev->audio_channels);
|
||||
if (ev->audio_channels_count) free(ev->audio_channels);
|
||||
ev->audio_channels_count = 0;
|
||||
}
|
||||
|
||||
|
@ -372,7 +372,7 @@ _video_channels_free(Emotion_Generic_Video *ev)
|
|||
int i;
|
||||
for (i = 0; i < ev->video_channels_count; i++)
|
||||
eina_stringshare_del(ev->video_channels[i].name);
|
||||
free(ev->video_channels);
|
||||
if (ev->video_channels_count) free(ev->video_channels);
|
||||
ev->video_channels_count = 0;
|
||||
}
|
||||
|
||||
|
@ -382,7 +382,7 @@ _spu_channels_free(Emotion_Generic_Video *ev)
|
|||
int i;
|
||||
for (i = 0; i < ev->spu_channels_count; i++)
|
||||
eina_stringshare_del(ev->spu_channels[i].name);
|
||||
free(ev->spu_channels);
|
||||
if (ev->spu_channels_count) free(ev->spu_channels);
|
||||
ev->spu_channels_count = 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue