[vlc-commits] codec/telx: Fix warning

2019-11-12 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Sat Nov  
9 16:27:42 2019 +0100| [eb06ce12b578bb5b0018ac9209098eddd988307e] | committer: 
Thomas Guillem

codec/telx: Fix warning

Make sure the dbg macro can't compile down to nothing, so it can be used in
if statements without braces.

codec/telx.c: In function ‘Decode’:
codec/telx.c:686:81: warning: suggest braces around empty body in an ‘if’
statement [-Wempty-body]
(long int)(p_sys->prev_pts+150)));
 ^

Signed-off-by: Thomas Guillem 

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

 modules/codec/telx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/codec/telx.c b/modules/codec/telx.c
index 8446e1a5f4..dc5259f4e2 100644
--- a/modules/codec/telx.c
+++ b/modules/codec/telx.c
@@ -40,7 +40,7 @@
 #ifdef TELX_DEBUG
 #   define dbg( a ) msg_Dbg a
 #else
-#   define dbg( a )
+#   define dbg( a ) (void) 0
 #endif
 
 /*

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits


[vlc-commits] objects: Add stream_{directory, extractor}_t to C++ VLC_OBJECT()

2019-11-05 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Mon Nov  
4 23:52:31 2019 +0100| [0e5178f7214a03cfe673e989bdfabad6853c9e60] | committer: 
Thomas Guillem

objects: Add stream_{directory, extractor}_t to C++ VLC_OBJECT()

Signed-off-by: Thomas Guillem 

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

 include/vlc_objects.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/vlc_objects.h b/include/vlc_objects.h
index 0c9e055034..19ee5207fc 100644
--- a/include/vlc_objects.h
+++ b/include/vlc_objects.h
@@ -91,6 +91,8 @@ vlc_object_cast(intf_thread_t)
 vlc_object_cast(vlc_player_t)
 vlc_object_cast(playlist_t)
 vlc_object_cast(stream_t)
+vlc_object_cast(stream_directory_t)
+vlc_object_cast(stream_extractor_t)
 vlc_object_cast(decoder_t)
 vlc_object_cast(filter_t)
 vlc_object_cast(audio_output)

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits


[vlc-commits] archive: Add support for RAR 5.0 format

2019-11-03 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Sun Nov  
3 00:23:00 2019 +0100| [059f6f5690005853f3e3160f5f896301b2f52ecd] | committer: 
Jean-Baptiste Kempf

archive: Add support for RAR 5.0 format

libarchive 3.4.0 adds support for RAR 5.0. See
https://www.rarlab.com/technote.htm#rarsign for description of signatures.

Signed-off-by: Jean-Baptiste Kempf 

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

 modules/stream_extractor/archive.c | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/modules/stream_extractor/archive.c 
b/modules/stream_extractor/archive.c
index 3498bd2fb9..f9493bbbd6 100644
--- a/modules/stream_extractor/archive.c
+++ b/modules/stream_extractor/archive.c
@@ -453,7 +453,10 @@ static int probe( stream_t* source )
 } const magicbytes[] = {
 /* keep heaviest at top */
 { 257, 5, "ustar" },  //TAR
-{ 0,   7, "Rar!\x1A\x07" },   //RAR
+#if ARCHIVE_VERSION_NUMBER >= 3004000
+{ 0,   8, "Rar!\x1A\x07\x01" },   //RAR5.0
+#endif
+{ 0,   7, "Rar!\x1A\x07" },   //RAR4.x
 { 0,   6, "7z\xBC\xAF\x27\x1C" }, //7z
 { 0,   4, "xar!" },   //XAR
 { 0,   4, "PK\x03\x04" }, //ZIP

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits


[vlc-commits] player: fix on_position_changed docs link

2019-07-11 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Wed Jul 
10 22:56:40 2019 +0200| [4858bcdbccb190e4c518b9625b31017e6c40ae65] | committer: 
Thomas Guillem

player: fix on_position_changed docs link

Signed-off-by: Thomas Guillem 

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

 include/vlc_player.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/vlc_player.h b/include/vlc_player.h
index df5b75b045..57fe35b826 100644
--- a/include/vlc_player.h
+++ b/include/vlc_player.h
@@ -1429,7 +1429,7 @@ vlc_player_GetLength(vlc_player_t *player);
  *
  * @note A started and playing media doesn't have necessarily a valid time.
  *
- * @see vlc_player_cbs.vlc_player_cbs.on_position_changed
+ * @see vlc_player_cbs.on_position_changed
  *
  * @param player locked player instance
  * @return a valid time or VLC_TICK_INVALID (if no media is set, the media

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits


[vlc-commits] logger: Fix warning

2019-06-16 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Sat Jun 
15 12:49:31 2019 +0200| [579a83abb6c21c416f84b98001ceb697c069e61d] | committer: 
Rémi Denis-Courmont

logger: Fix warning

logger/journal.c: In function ‘Open’:
logger/journal.c:75:12: warning: return from incompatible pointer type 
[-Wincompatible-pointer-types]
 return 
^~~~

Signed-off-by: Rémi Denis-Courmont 

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

 modules/logger/journal.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/logger/journal.c b/modules/logger/journal.c
index 83111be107..9e0f6a624e 100644
--- a/modules/logger/journal.c
+++ b/modules/logger/journal.c
@@ -66,7 +66,7 @@ static void Log(void *opaque, int type, const vlc_log_t *meta,
 
 static const struct vlc_logger_operations ops = { Log, NULL };
 
-static vlc_log_cb Open(vlc_object_t *obj, void **sysp)
+static const struct vlc_logger_operations *Open(vlc_object_t *obj, void **sysp)
 {
 if (!var_InheritBool(obj, "syslog"))
 return NULL;

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits


[vlc-commits] hw: vaapi: fix a few warnings

2019-01-17 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Thu Jan 
17 20:40:04 2019 +0100| [981a31858ff30f0d0371a08123b0dfbe46c781ac] | committer: 
Steve Lhomme

hw: vaapi: fix a few warnings

hw/vaapi/filters.c:296:9: warning: variable 'pipeline_buf' is used 
uninitialized whenever 'if' condition is true
  [-Wsometimes-uninitialized]
if (vlc_vaapi_BeginPicture(VLC_OBJECT(filter),
^~
hw/vaapi/filters.c:344:9: note: uninitialized use occurs here
if (pipeline_buf != VA_INVALID_ID)
^~~~
hw/vaapi/filters.c:296:5: note: remove the 'if' if its condition is always false
if (vlc_vaapi_BeginPicture(VLC_OBJECT(filter),
^~
hw/vaapi/filters.c:292:9: warning: variable 'pipeline_buf' is used 
uninitialized whenever 'if' condition is true
  [-Wsometimes-uninitialized]
if (vlc_vaapi_UnmapBuffer(VLC_OBJECT(filter),
^
hw/vaapi/filters.c:344:9: note: uninitialized use occurs here
if (pipeline_buf != VA_INVALID_ID)
^~~~
hw/vaapi/filters.c:292:5: note: remove the 'if' if its condition is always false
if (vlc_vaapi_UnmapBuffer(VLC_OBJECT(filter),
^
hw/vaapi/filters.c:285:9: warning: variable 'pipeline_buf' is used 
uninitialized whenever 'if' condition is true
  [-Wsometimes-uninitialized]
if (vlc_vaapi_MapBuffer(VLC_OBJECT(filter), filter_sys->va.dpy,
^~~
hw/vaapi/filters.c:344:9: note: uninitialized use occurs here
if (pipeline_buf != VA_INVALID_ID)
^~~~
hw/vaapi/filters.c:285:5: note: remove the 'if' if its condition is always false
if (vlc_vaapi_MapBuffer(VLC_OBJECT(filter), filter_sys->va.dpy,
^~~
hw/vaapi/filters.c:304:5: note: variable 'pipeline_buf' is declared here
VABufferID  pipeline_buf = VA_INVALID_ID;
^
9 warnings generated.

Signed-off-by: Steve Lhomme 

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

 modules/hw/vaapi/filters.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/hw/vaapi/filters.c b/modules/hw/vaapi/filters.c
index a27b102376..482321d969 100644
--- a/modules/hw/vaapi/filters.c
+++ b/modules/hw/vaapi/filters.c
@@ -273,6 +273,7 @@ Filter(filter_t * filter, picture_t * src,
  VAProcPipelineParameterBuffer *))
 {
 filter_sys_t *const filter_sys = filter->p_sys;
+VABufferID  pipeline_buf = VA_INVALID_ID;
 picture_t *constdest = picture_pool_Wait(filter_sys->dest_pics);
 if (!dest)
 return NULL;
@@ -301,7 +302,6 @@ Filter(filter_t * filter, picture_t * src,
 if (pf_prepare_render_surface)
 pf_prepare_render_surface(filter_sys->p_data);
 
-VABufferID  pipeline_buf = VA_INVALID_ID;
 VAProcPipelineParameterBuffer * pipeline_params;
 
 pipeline_buf =

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits


[vlc-commits] display: fix a few warnings

2019-01-16 Thread Johan Gunnarsson
vlc | branch: master | Johan Gunnarsson  | Wed Jan 
16 22:07:33 2019 +0100| [3668542df0656e9c5a6d958695ee34646b1ae638] | committer: 
Steve Lhomme

display: fix a few warnings

video_output/display.c: In function ‘vout_display_TranslateMouseState’:
video_output/display.c:262:23: warning: ‘y’ may be used uninitialized in this 
function [-Wmaybe-uninitialized]
 + (int64_t)(y - place.y) * vd->source.i_visible_height / place.height;
~~~^~
video_output/display.c:260:23: warning: ‘x’ may be used uninitialized in this 
function [-Wmaybe-uninitialized]
 + (int64_t)(x - place.x) * vd->source.i_visible_width / place.width;
~~~^~

Signed-off-by: Steve Lhomme 

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

 src/video_output/display.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/video_output/display.c b/src/video_output/display.c
index be744e0b98..0b34e8277f 100644
--- a/src/video_output/display.c
+++ b/src/video_output/display.c
@@ -254,6 +254,8 @@ void vout_display_TranslateMouseState(vout_display_t *vd, 
vlc_mouse_t *video,
 x = place.height - wy;
 y = place.width - wx;
 break;
+default:
+vlc_assert_unreachable();
 }
 
 video->i_x = vd->source.i_x_offset

___
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits