[vlc-commits] lua: kill a warning

Ludovic Fauvet git at videolan.org
Wed Mar 16 23:28:23 CET 2016


vlc | branch: master | Ludovic Fauvet <etix at videolan.org> | Wed Mar 16 23:12:27 2016 +0100| [c4458c71ff1bdadc1c173bd1acf78f3e887e8795] | committer: Ludovic Fauvet

lua: kill a warning

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

 modules/lua/libs/net.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/modules/lua/libs/net.c b/modules/lua/libs/net.c
index 071bd29..c471ead 100644
--- a/modules/lua/libs/net.c
+++ b/modules/lua/libs/net.c
@@ -131,7 +131,7 @@ static int vlclua_fd_get_lua( lua_State *L, int fd )
 static void vlclua_fd_unmap( lua_State *L, unsigned idx )
 {
     vlclua_dtable_t *dt = vlclua_get_dtable( L );
-    int fd = -1;
+    int fd;
 
     if( idx < 3u )
         return; /* Never close stdin/stdout/stderr. */
@@ -148,6 +148,8 @@ static void vlclua_fd_unmap( lua_State *L, unsigned idx )
 #ifndef NDEBUG
     for( unsigned i = 0; i < dt->fdc; i++ )
         assert( dt->fdv[i] != fd );
+#else
+    (void) fd;
 #endif
 }
 



More information about the vlc-commits mailing list