[vlc-commits] demux: vobsub: don't use failed picture dimensions scan

Francois Cartegnie git at videolan.org
Tue Oct 8 19:15:14 CEST 2019


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Tue Oct  8 15:55:33 2019 +0200| [d87480529596a60484e5e2aeb5c05b0596e32919] | committer: Francois Cartegnie

demux: vobsub: don't use failed picture dimensions scan

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=d87480529596a60484e5e2aeb5c05b0596e32919
---

 modules/demux/vobsub.h | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/modules/demux/vobsub.h b/modules/demux/vobsub.h
index 1d980bc0e6..55ae0cf64e 100644
--- a/modules/demux/vobsub.h
+++ b/modules/demux/vobsub.h
@@ -62,9 +62,11 @@ static inline int vobsub_size_parse( const char *psz_buf,
                                      int *pi_original_frame_width,
                                      int *pi_original_frame_height )
 {
-    if( sscanf( psz_buf, "size: %dx%d",
-                pi_original_frame_width, pi_original_frame_height ) == 2 )
+    int w, h;
+    if( sscanf( psz_buf, "size: %dx%d", &w, &h ) == 2 )
     {
+        *pi_original_frame_width = w;
+        *pi_original_frame_height = h;
         return VLC_SUCCESS;
     }
     else



More information about the vlc-commits mailing list