Opened 15 years ago

Closed 15 years ago

#1885 closed defect (fixed)

FTDEMO: Memoryleak in SMUSH player

Reported by: anotherguest Owned by: fingolfin
Priority: normal Component: Engine: SCUMM
Keywords: Cc:
Game: Full Throttle

Description

In a couple places in the smush_player.cpp a special
buffer is created when the videoheight & width is
242x384. But no check is made to see if the
_specialBuffer already has been allocated. I think it
should look like this

if ((height == 242) && (width == 384)) {
if(_specialBuffer == NULL)
_specialBuffer = (byte *)malloc(242 * 384);
_dst = _specialBuffer;
} else if ((height > _vm->_screenHeight) || (width >
_vm->
...

instead of

if ((height == 242) && (width == 384)) {
_dst = _specialBuffer = (byte *)malloc(242 * 384);
}
else
...

Ticket imported from: #1098872. Ticket imported from: bugs/1885.

Change History (4)

comment:1 by fingolfin, 15 years ago

Owner: changed from sev- to aquadran

comment:2 by fingolfin, 15 years ago

I wonder when that buffer is used, ever...

comment:3 by aquadran, 15 years ago

yes, that check should be exist
that is hack for ft demo excteption when frame buffer is
bigger then normal 320x200 size.

comment:4 by fingolfin, 15 years ago

Component: --Unset--Engine: SCUMM
Game: Full Throttle
Owner: changed from aquadran to fingolfin
Resolution: fixed
Status: newclosed
Summary: Memoryleak in SMUSH playerFTDEMO: Memoryleak in SMUSH player
Note: See TracTickets for help on using tickets.