Changeset 435 for trunk/src/lua/lua_raw.cc
- Timestamp:
- 07/22/15 21:00:30 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lua/lua_raw.cc
r406 r435 26 26 default : break; 27 27 } 28 char buffer[64]; 28 char buffer_data[64]; 29 nv::array_ref< char > buffer( buffer_data, 64 ); 29 30 if ( type == LUA_TLIGHTUSERDATA || type == LUA_TUSERDATA ) 30 31 { 31 size_t l = nv::uint64_to_buffer( nv::uint64( lua_touserdata( L, idx ) ), buffer);32 return std::string( buffer , l );32 size_t l = nv::uint64_to_buffer( buffer, nv::uint64( lua_touserdata( L, idx ) ) ); 33 return std::string( buffer_data, l ); 33 34 } 34 35 else if ( type == LUA_TNUMBER ) 35 36 { 36 size_t l = nv::f64_to_buffer( lua_tonumber( L, idx ), buffer);37 return std::string( buffer , l );37 size_t l = nv::f64_to_buffer( buffer, lua_tonumber( L, idx ) ); 38 return std::string( buffer_data, l ); 38 39 } 39 40 return "UNKNOWN!";
Note: See TracChangeset
for help on using the changeset viewer.