Merge branch 'development' of https://github.com/GarageGames/Torque3D into memberMess

# Conflicts:
#	Engine/source/console/consoleFunctions.cpp
This commit is contained in:
Azaezel 2018-03-28 15:42:34 -05:00
commit cbce2ee805
154 changed files with 2950 additions and 705 deletions

View file

@ -177,8 +177,9 @@ bool CentralDir::write(Stream *stream)
void CentralDir::setFileComment(const char *comment)
{
SAFE_DELETE_ARRAY(mFileComment);
mFileComment = new char [dStrlen(comment)+1];
dStrcpy(mFileComment, comment);
dsize_t commentLen = dStrlen(comment) + 1;
mFileComment = new char [commentLen];
dStrcpy(mFileComment, comment, commentLen);
}
//-----------------------------------------------------------------------------

View file

@ -95,7 +95,7 @@ private:
{
// Find a unique filename
U32 count = 1;
dStrcpy(fileBuf, filename);
dStrcpy(fileBuf, filename, bufSize);
while(zip->findFileInfo(fileBuf))
{
@ -109,7 +109,7 @@ private:
}
}
else if(fileBuf && bufSize > 0)
dStrcpy(fileBuf, filename);
dStrcpy(fileBuf, filename, bufSize);
// Try and write to the file
Stream * stream = zip->openFile(fileBuf ? fileBuf : filename, ZipArchive::Write);