CGE2: Use snprintf() instead of sprintf().

This commit is contained in:
uruk 2014-08-11 20:43:08 +02:00
parent e488da5757
commit ae037b2315
2 changed files with 2 additions and 2 deletions

View file

@ -387,7 +387,7 @@ void CGE2Engine::movie(const char *ext) {
return;
char fn[12];
sprintf(fn, "CGE%s", ext);
snprintf(fn, 12, "CGE%s", ext);
if (_resman->exist(fn)) {
int now = _now;

View file

@ -190,7 +190,7 @@ void Text::sayTime(Sprite *spr) {
_vm->_system->getTimeAndDate(curTime);
char t[6];
sprintf(t, "%d:%02d", curTime.tm_hour, curTime.tm_min);
snprintf(t, 6, "%d:%02d", curTime.tm_hour, curTime.tm_min);
say(t, spr);
}