Opened 16 years ago

Closed 16 years ago

Last modified 6 years ago

#8975 closed patch

Buffer Overflow

Reported by: SF/reddwarf69 Owned by: wjp
Priority: normal Component: --Other--
Version: Keywords:
Cc: Game:

Description

From openSUSE rpmlint... I: Statement might be overflowing a buffer in strncat. Common mistake: BAD: strncat(buffer,charptr,sizeof(buffer)) is wrong, it takes the left over size as 3rd argument GOOD: strncat(buffer,charptr,sizeof(buffer)-strlen(buffer)-1) E: scummvm bufferoverflowstrncat engines/saga/sfuncs.cpp:1573 E: scummvm bufferoverflowstrncat engines/scumm/he/logic_he.cpp:89

No especially efficient (too much strlen()) but fixes the problem.

Ticket imported from: #2671477. Ticket imported from: patches/1080.

Attachments (1)

scummvm-0.13-bufferoverflow.patch (740 bytes ) - added by SF/reddwarf69 16 years ago.
Fix

Download all attachments as: .zip

Change History (4)

by SF/reddwarf69, 16 years ago

Fix

comment:1 by wjp, 16 years ago

Thanks! Committed as-is as r39184.

comment:2 by wjp, 16 years ago

Owner: set to wjp
Status: newclosed

comment:3 by digitall, 6 years ago

Component: --Other--
Note: See TracTickets for help on using tickets.