diff options
author | wolfbeast <mcwerewolf@wolfbeast.com> | 2019-03-23 11:10:28 +0100 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2019-03-23 11:10:28 +0100 |
commit | 10982181db01134d2369aa000b3adde69e1e495d (patch) | |
tree | 8c808d8a68de1ac86a3b7fc4b34e66862d92445e | |
parent | 3cfdf908cc5e967efd3302f2b4be9a33d31ac5ae (diff) | |
download | UXP-10982181db01134d2369aa000b3adde69e1e495d.tar UXP-10982181db01134d2369aa000b3adde69e1e495d.tar.gz UXP-10982181db01134d2369aa000b3adde69e1e495d.tar.lz UXP-10982181db01134d2369aa000b3adde69e1e495d.tar.xz UXP-10982181db01134d2369aa000b3adde69e1e495d.zip |
Check for osint argument when checking for greomni and appomni arguments.
Specifying both is invalid and unsupported.
-rw-r--r-- | toolkit/xre/nsAppRunner.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp index 59a72c432..26e432b3c 100644 --- a/toolkit/xre/nsAppRunner.cpp +++ b/toolkit/xre/nsAppRunner.cpp @@ -4130,9 +4130,12 @@ XRE_InitCommandLine(int aArgc, char* aArgv[]) #endif const char *path = nullptr; - ArgResult ar = CheckArg("greomni", false, &path); + ArgResult ar = CheckArg("greomni", true, &path); if (ar == ARG_BAD) { - PR_fprintf(PR_STDERR, "Error: argument --greomni requires a path argument\n"); + PR_fprintf(PR_STDERR, + "Error: argument --greomni requires a path argument or the " + "--osint argument was specified with the --greomni argument " + "which is invalid.\n"); return NS_ERROR_FAILURE; } @@ -4146,9 +4149,12 @@ XRE_InitCommandLine(int aArgc, char* aArgv[]) return rv; } - ar = CheckArg("appomni", false, &path); + ar = CheckArg("appomni", true, &path); if (ar == ARG_BAD) { - PR_fprintf(PR_STDERR, "Error: argument --appomni requires a path argument\n"); + PR_fprintf(PR_STDERR, + "Error: argument --appomni requires a path argument or the " + "--osint argument was specified with the --appomni argument " + "which is invalid.\n"); return NS_ERROR_FAILURE; } |