summaryrefslogtreecommitdiffstats
path: root/mplayer.c
diff options
context:
space:
mode:
authorUoti Urpala <uau@glyph.nonexistent.invalid>2011-01-19 18:00:22 +0200
committerUoti Urpala <uau@glyph.nonexistent.invalid>2011-01-26 13:04:17 +0200
commit8612c771fcb7321a2d6e0ba79f6f3cf26ee7f70c (patch)
tree9beda246875d7df74496c78f3dace0404260b6ff /mplayer.c
parent6d65f6889af5c4ad8874f59d97e73053fa31aba5 (diff)
downloadmpv-8612c771fcb7321a2d6e0ba79f6f3cf26ee7f70c.tar.bz2
mpv-8612c771fcb7321a2d6e0ba79f6f3cf26ee7f70c.tar.xz
cleanup: some random minor code simplification and cleanup
Diffstat (limited to 'mplayer.c')
-rw-r--r--mplayer.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/mplayer.c b/mplayer.c
index 1c41e35f9d..00d568b359 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -1093,9 +1093,8 @@ void add_subtitles(struct MPContext *mpctx, char *filename, float fps, int noerr
sub_data *subd = NULL;
struct ass_track *asst = NULL;
- if (filename == NULL || mpctx->set_of_sub_size >= MAX_SUBTITLE_FILES) {
+ if (filename == NULL || mpctx->set_of_sub_size >= MAX_SUBTITLE_FILES)
return;
- }
#ifdef CONFIG_ASS
if (opts->ass_enabled) {
@@ -1108,10 +1107,8 @@ void add_subtitles(struct MPContext *mpctx, char *filename, float fps, int noerr
subd = sub_read_file(filename, fps, &mpctx->opts);
if (subd) {
asst = ass_read_subdata(ass_library, subd, fps);
- if (asst) {
- sub_free(subd);
- subd = NULL;
- }
+ sub_free(subd);
+ subd = NULL;
}
}
} else