Removed const from argv

This commit is contained in:
Bob Polis 2022-09-28 17:05:44 +02:00
parent cff4e5e903
commit 058f4023ea

View File

@ -80,7 +80,7 @@ bool handle_window_resize(const SDL_Event& event, bool quit) {
return quit; return quit;
} }
int main(int argc, const char * argv[]) { int main(int argc, char* argv[]) {
try { try {
// gather plugins // gather plugins
#if DEBUG #if DEBUG
@ -101,7 +101,7 @@ int main(int argc, const char * argv[]) {
{"version", no_argument, &opt_val, 1}, {"version", no_argument, &opt_val, 1},
{nullptr, 0, nullptr, 0} {nullptr, 0, nullptr, 0}
}; };
while ((opt_char = getopt_long(argc, const_cast<char* const *>(argv), "hlrw", long_options, nullptr)) != -1) { while ((opt_char = getopt_long(argc, argv, "hlrw", long_options, nullptr)) != -1) {
std::string arg {optarg ? optarg : ""}; std::string arg {optarg ? optarg : ""};
switch (opt_char) { switch (opt_char) {
case 0: { case 0: {