Opened 16 years ago

Closed 16 years ago

#3854 closed defect

DRASCULA: Mem leak

Reported by: SF/knakos Owned by: fingolfin
Priority: normal Component: Engine: Drascula
Version: Keywords:
Cc: Game: Drascula

Description

The drascula engine is currently leaking memory through its arj class, rendering the game unplayble in small devices (letting the whole intro run it eats up 35MB approx.). I have commited a fix around it (r33716,33717), where the open method frees any previously allocated memory block before allocating a new one. This makes the game playble (it wouldn't run otherwise).

The "proper" solution is to fix those memory leaks in the engine.

Ticket imported from: #2044157. Ticket imported from: bugs/3854.

Change History (4)

comment:1 by fingolfin, 16 years ago

I recently rewrote the Arj code, and hope that it's leak free now. Testing would be highly welcome.

Though you said the bug should be fixed in the *engine*, which confuses me. Do you mean that there are additional bugs / leaks in the engine?

comment:2 by SF/knakos, 16 years ago

This is IIRC fingolfin: When I studied the code back then, drascula was opening new arj files without closing the previously open ones. So, in practice, the code would open a file, load some data and not close it when finished. This lack of symmetry must have been the source of this comment.

comment:3 by fingolfin, 16 years ago

Owner: changed from sev- to fingolfin
Status: newclosed

comment:4 by fingolfin, 16 years ago

OK, then I'll close this.

Note: See TracTickets for help on using tickets.