Introduce a command line option to pass sleep password.

And fix return code for "launching" system app.
This commit is contained in:
mdaftari
2018-10-26 15:22:08 -07:00
parent 231dd4e462
commit 3e6d3981ac
3 changed files with 38 additions and 11 deletions

View File

@@ -61,6 +61,8 @@ static char spUuid[BUFSIZE];
extern bool wakeOnWifiLan;
static int gDialPort;
char spSleepPassword[BUFSIZE];
static char *spAppYouTube = "chrome";
static char *spAppYouTubeMatch = "chrome.*google-chrome-dial";
static char *spAppYouTubeExecutable = "/opt/google/chrome/google-chrome";
@@ -325,6 +327,9 @@ static void processOption( int index, char * pOption )
exit(1);
}
break;
case 6:
setValue( pOption, spSleepPassword );
break;
default:
// Should not get here
fprintf( stderr, "Option %d not valid\n", index);