[vlc-commits] vgl: don't call cleanup callback if nothing has done
Zhao Zhili
git at videolan.org
Thu Aug 23 15:06:25 CEST 2018
vlc | branch: master | Zhao Zhili <quinkblack at foxmail.com> | Thu Aug 23 17:24:19 2018 +0800| [1089b77dc9f315f946881f38250d04bf265da270] | committer: Thomas Guillem
vgl: don't call cleanup callback if nothing has done
Signed-off-by: Thomas Guillem <thomas at gllm.fr>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=1089b77dc9f315f946881f38250d04bf265da270
---
modules/video_output/vgl.c | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/modules/video_output/vgl.c b/modules/video_output/vgl.c
index 6af8c674e4..6a69a3751e 100644
--- a/modules/video_output/vgl.c
+++ b/modules/video_output/vgl.c
@@ -99,7 +99,7 @@ static void Close(vlc_object_t *object)
var = var_InheritAddress(gl, varname); \
if( !var ) { \
msg_Err( gl, "%s address is missing", varname ); \
- goto error; \
+ return VLC_EGENERIC; \
} \
} while( 0 )
@@ -131,14 +131,10 @@ static int Open(vlc_object_t *object)
if( !sys->setupCb(sys->opaque) )
{
msg_Err( gl, "user setup failed" );
- goto error;
+ return VLC_EGENERIC;
}
return VLC_SUCCESS;
-
-error:
- Close(object);
- return VLC_EGENERIC;
}
#undef SET_CALLBACK_ADDR
More information about the vlc-commits
mailing list