Fix warnings about unused params in C code
authorWuzzy <Wuzzy2@mail.ru>
Sun, 22 Jul 2018 02:29:44 +0200
changeset 13537 ecdf6ce2301e
parent 13536 2694e8449a2a
child 13538 f8c0a62fa3ac
Fix warnings about unused params in C code
hedgewars/avwrapper/avwrapper.c
misc/libphyslayer/physfslualoader.c
--- a/hedgewars/avwrapper/avwrapper.c	Sat Jul 21 15:58:07 2018 +0200
+++ b/hedgewars/avwrapper/avwrapper.c	Sun Jul 22 02:29:44 2018 +0200
@@ -35,6 +35,8 @@
 #define AVWRAP_DECL
 #endif
 
+#define UNUSED(x) (void)(x)
+
 static AVFormatContext* g_pContainer;
 static AVOutputFormat* g_pFormat;
 static AVStream* g_pAStream;
@@ -138,6 +140,9 @@
 // (there is mutex in AddFileLogRaw).
 static void LogCallback(void* p, int Level, const char* pFmt, va_list VaArgs)
 {
+    UNUSED(p);
+    UNUSED(Level);
+
     char Buffer[1024];
 
     vsnprintf(Buffer, 1024, pFmt, VaArgs);
--- a/misc/libphyslayer/physfslualoader.c	Sat Jul 21 15:58:07 2018 +0200
+++ b/misc/libphyslayer/physfslualoader.c	Sun Jul 22 02:29:44 2018 +0200
@@ -4,11 +4,13 @@
 #include "physfscompat.h"
 
 #define BUFSIZE 1024
+#define UNUSED(x) (void)(x)
 
 void *physfsReaderBuffer;
 
 PHYSFS_DECL const char * physfsReader(lua_State *L, PHYSFS_File *f, size_t *size)
 {
+    UNUSED(L);
 
     if(PHYSFS_eof(f))
     {