/* Set default configuration and copy arguments */
/* Set default configuration and copy arguments */
p_main->i_argc=i_argc;
p_main->i_argc=*i_argc;
p_main->ppsz_argv=ppsz_argv;
p_main->ppsz_argv=ppsz_argv;
p_main->ppsz_env=ppsz_env;
p_main->ppsz_env=ppsz_env;
...
@@ -534,9 +534,22 @@ static int GetConfiguration( int i_argc, char *ppsz_argv[], char *ppsz_env[] )
...
@@ -534,9 +534,22 @@ static int GetConfiguration( int i_argc, char *ppsz_argv[], char *ppsz_env[] )
}
}
}
}
//when vlc.app is run by double clicking in Mac OS X, the 2nd arg is the PSN - process serial number (a unique PID-ish thingie)
//still ok for real Darwin & when run from command line
#ifdef SYS_DARWIN1_3
if(strncmp(ppsz_argv[1],"-psn",4)==0)//for example -psn_0_9306113
{
//ppsz_argv[ 1 ] = NULL; //GDMF!... I can't do this or else the MacOSX window server will not pick up the PSN and not register the app and we crash...hence the following kludge
//otherwise we'll get confused w/ argv[1] being an input file name