Fix too small char buffer.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@2161 dfc29bdd-3216-0410-991c-e03cc46cb475
master
hybrid 2009-01-28 23:23:30 +00:00
parent 72e38c419e
commit 8ca2ea0fd5
2 changed files with 5 additions and 5 deletions

View File

@ -321,9 +321,9 @@ void CNullDriver::renameTexture(ITexture* texture, const core::string<c16>& newN
ITexture* CNullDriver::getTexture(const core::string<c16>& filename)
{
// Identify textures by their absolute filenames if possible.
core::string<c16> absolutePath = FileSystem->getAbsolutePath(filename);
const core::string<c16> absolutePath = FileSystem->getAbsolutePath(filename);
ITexture* texture = findTexture(absolutePath );
ITexture* texture = findTexture(absolutePath);
if (texture)
return texture;
@ -333,7 +333,7 @@ ITexture* CNullDriver::getTexture(const core::string<c16>& filename)
return texture;
// Now try to open the file using the complete path.
io::IReadFile* file = FileSystem->createAndOpenFile(absolutePath );
io::IReadFile* file = FileSystem->createAndOpenFile(absolutePath);
if(!file)
{

View File

@ -45,9 +45,9 @@ CSoftwareTexture2::CSoftwareTexture2(IImage* image, const core::string<c16>& nam
}
else
{
char buf[128];
char buf[256];
core::stringw showName ( name );
snprintf ( buf, 128, "Burningvideo: Warning Texture %ls reformat %dx%d -> %dx%d,%d",
snprintf ( buf, 256, "Burningvideo: Warning Texture %ls reformat %dx%d -> %dx%d,%d",
showName.c_str(),
OrigSize.Width, OrigSize.Height, optSize.Width, optSize.Height,
BURNINGSHADER_COLOR_FORMAT