From 8f6495be0bad41ba9603928cbb0990a6b434afa8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Sun, 12 Oct 2014 16:41:15 -0700 Subject: [PATCH] SDL2: Fixed args. --- examples/common/entry/entry_sdl.cpp | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/examples/common/entry/entry_sdl.cpp b/examples/common/entry/entry_sdl.cpp index 1b5c000cf..f399b7d0b 100644 --- a/examples/common/entry/entry_sdl.cpp +++ b/examples/common/entry/entry_sdl.cpp @@ -215,11 +215,10 @@ namespace entry initTranslateKey(SDL_SCANCODE_Z, Key::KeyZ); } - void run() + void run(int _argc, char** _argv) { - const char* argv[1] = { "sdl.so" }; - m_mte.m_argc = 1; - m_mte.m_argv = const_cast(argv); + m_mte.m_argc = _argc; + m_mte.m_argv = _argv; SDL_Init(SDL_INIT_VIDEO); @@ -634,11 +633,10 @@ namespace entry } // namespace entry -int main(int _argc, const char* _argv[]) +int main(int _argc, char** _argv) { - BX_UNUSED(_argc, _argv); using namespace entry; - s_ctx.run(); + s_ctx.run(_argc, _argv); return 0; }