[libdvdcss-devel] Replace GCC-specific bits in print_debug macro by standards-compliant code.

[email protected] (Diego Biurrun)
Newsgroups gmane.comp.video.videolan.libdvdcss,gmane.comp.video.videolan.libdvdcss.devel
Message-ID <[email protected]>
libdvdcss | branch: master | Diego Biurrun <[email protected]> | Mon Oct 27 18:04:48 2014 +0100| [f40f3803ae5f56c93f53f5ea29fc55c10a9473a5] | committer: Diego Biurrun

Replace GCC-specific bits in print_debug macro by standards-compliant code.

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

 src/libdvdcss.h |   18 ++----------------
 1 file changed, 2 insertions(+), 16 deletions(-)

diff --git a/src/libdvdcss.h b/src/libdvdcss.h
index 71e8daf..4ef1183 100644
--- a/src/libdvdcss.h
+++ b/src/libdvdcss.h
@@ -87,27 +87,13 @@ struct dvdcss_s
 /*****************************************************************************
  * Functions used across the library
  *****************************************************************************/
-#if defined( _MSC_VER )
-#include <stdarg.h>
-__forceinline void print_debug(dvdcss_t dvdcss, const char *msg,...)
-{
-    va_list args;
-
-    fprintf( stderr, "libdvdcss debug: " );
-    va_start( args, msg );
-    vfprintf( stderr, msg, args );
-    va_end( args );
-    fprintf( stderr, "\n" );
-}
-#else
-#define print_debug(dvdcss,msg,args...) \
+#define print_debug( dvdcss, ... ) \
     if( dvdcss->b_debug ) \
     { \
         fprintf( stderr, "libdvdcss debug: " ); \
-        fprintf( stderr, msg, ##args ); \
+        fprintf( stderr, __VA_ARGS__ ); \
         fprintf( stderr, "\n" ); \
     }
-#endif
 
 void print_error ( dvdcss_t, char * );
 

_______________________________________________
libdvdcss-devel mailing list
[email protected]
https://mailman.videolan.org/listinfo/libdvdcss-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.