mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
Fix: dSprintf should receive size of the buffer, not the size of the pointer.
It was safe, as we are using static console return buffer, which is large enough to hold enough data (default is 2048).
This commit is contained in:
parent
c7a5a12080
commit
68b12981ae
2 changed files with 2 additions and 2 deletions
|
|
@ -79,7 +79,7 @@ ConsoleMethod(DbgFileView, getCurrentLine, const char *, 2, 2, "()"
|
|||
S32 lineNum;
|
||||
const char *file = object->getCurrentLine(lineNum);
|
||||
char* ret = Con::getReturnBuffer(256);
|
||||
dSprintf(ret, sizeof(ret), "%s\t%d", file, lineNum);
|
||||
dSprintf(ret, 256, "%s\t%d", file, lineNum);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue