rude  committed eeacea0

Added missing lua_strlen to ThreadVariant construction. MSVC coerced the 'const char*'-argument into the bool version of the constructor, causing the wrong function to be called.

  • Participants
  • Parent commits 348b7de

Comments (0)

Files changed (1)

File src/modules/thread/sdl/Thread.cpp

 		if(luaL_dostring(L, comm->getCode()) == 1)
 			SDL_mutexP((SDL_mutex*) comm->mutex);
-			ThreadVariant *v = new ThreadVariant(lua_tostring(L, -1));
+			ThreadVariant *v = new ThreadVariant(lua_tostring(L, -1), lua_strlen(L, -1));
 			comm->setValue("error", v);
 			SDL_mutexV((SDL_mutex*) comm->mutex);