1
mirror of https://code.videolan.org/videolan/vlc synced 2024-10-15 08:37:59 +02:00

Win32: move MessageBox error from libVLC to vlc.exe

One might want to handle libvlc creation errors in a different way
This commit is contained in:
Jean-Baptiste Kempf 2013-03-14 16:57:37 +01:00
parent c51906de3a
commit dcc36eb2ef
2 changed files with 6 additions and 5 deletions

View File

@ -154,6 +154,12 @@ int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance,
libvlc_wait (vlc);
libvlc_release (vlc);
}
else
MessageBox (NULL, TEXT("VLC media player could not start.\n"
"Either the command line options were invalid or no plugins were found.\n"),
TEXT("VLC media player"),
MB_OK|MB_ICONERROR);
for (int i = 0; i < argc; i++)
free (argv[i]);

View File

@ -201,11 +201,6 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
int vlc_optind;
if( config_LoadCmdLine( p_libvlc, i_argc, ppsz_argv, &vlc_optind ) )
{
#ifdef WIN32
MessageBox (NULL, TEXT("The command line options could not be parsed.\n"
"Make sure they are valid."), TEXT("VLC media player"),
MB_OK|MB_ICONERROR);
#endif
module_EndBank (true);
return VLC_EGENERIC;
}