CGE2: Use snprintf() instead of sprintf().
This commit is contained in:
parent
e488da5757
commit
ae037b2315
2 changed files with 2 additions and 2 deletions
|
@ -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;
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue