浏览代码

vsprintf replacement with engine vairant

resolves first issue in
https://github.com/GarageGames/Torque3D/issues/1515#issuecomment-184446719
Azaezel 9 年之前
父节点
当前提交
d25b03cd52
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Engine/source/core/stream/stream.cpp

+ 1 - 1
Engine/source/core/stream/stream.cpp

@@ -128,7 +128,7 @@ bool Stream::writeFormattedBuffer(const char *format, ...)
    char buffer[4096];
    va_list args;
    va_start(args, format);
-   const S32 length = vsprintf(buffer, format, args);
+   const S32 length = dVsprintf(buffer, sizeof(buffer), format, args);
 
    // Sanity!
    AssertFatal(length <= sizeof(buffer), "writeFormattedBuffer - String format exceeded buffer size.  This will cause corruption.");