]> git.sesse.net Git - vlc/commitdiff
Win32: disable Console output of help in WSA mode
authorJean-Baptiste Kempf <jb@videolan.org>
Tue, 22 Jan 2013 10:33:12 +0000 (11:33 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Tue, 22 Jan 2013 13:01:46 +0000 (14:01 +0100)
Calling AllocConsole does not work all the time in Metro mode,
and is supposed to be an undefined behaviour.

src/config/help.c

index bc9dd8282ece300b9bb374c324dee25d3dcca167..15a515302e375ddd54eb8cf5bf44ae6228faf62a 100644 (file)
@@ -34,7 +34,7 @@
 #include "config/configuration.h"
 #include "libvlc.h"
 
-#if defined( WIN32 )
+#if defined( WIN32 ) && !defined(WINAPI_FAMILY_APP)
 static void ShowConsole (void);
 static void PauseConsole (void);
 #else
@@ -796,7 +796,7 @@ static void Version( void )
     PauseConsole();
 }
 
-#if defined (WIN32)
+#if defined( WIN32 ) && !defined(WINAPI_FAMILY_APP)
 /*****************************************************************************
  * ShowConsole: On Win32, create an output console for debug messages
  *****************************************************************************
@@ -861,7 +861,7 @@ static int ConsoleWidth( void )
             i_width = 80;
         pclose( file );
     }
-#else
+#elif !defined(WINAPI_FAMILY_APP)
     CONSOLE_SCREEN_BUFFER_INFO buf;
 
     if (GetConsoleScreenBufferInfo (GetStdHandle (STD_OUTPUT_HANDLE), &buf))