[vlc-devel] [PATCH] demux/adaptive: FakeESOut: silence warning (unused expression)

Filip Roséen filip at atch.se
Fri Mar 17 03:35:50 CET 2017


Most compilers recognize static_cast<void>( ... ) as a mechanism to
silence warnings related to unused expressions, the previous
implementation however casted the result to void* which at all does
not have the same semantics.
---
 modules/demux/adaptive/plumbing/FakeESOut.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/demux/adaptive/plumbing/FakeESOut.cpp b/modules/demux/adaptive/plumbing/FakeESOut.cpp
index 92b1e5765c..a7b99c138a 100644
--- a/modules/demux/adaptive/plumbing/FakeESOut.cpp
+++ b/modules/demux/adaptive/plumbing/FakeESOut.cpp
@@ -406,7 +406,7 @@ int FakeESOut::esOutControl_Callback(es_out_t *fakees, int i_query, va_list args
         /* For others, we don't have the delorean, so always lie */
         case ES_OUT_GET_ES_STATE:
         {
-            static_cast<void*>(va_arg( args, es_out_id_t * ));
+            static_cast<void>(va_arg( args, es_out_id_t * ));
             bool *pb = static_cast<bool *>(va_arg( args, bool * ));
             *pb = true;
             // ft
-- 
2.12.0


More information about the vlc-devel mailing list