mirror of
https://github.com/libretro/scummvm.git
synced 2025-04-02 14:51:40 +00:00
Added constructor and destructor to Dialogue, thus fixing a long standing leak.
svn-id: r32757
This commit is contained in:
parent
4e2e46f16c
commit
d2609258cc
@ -207,6 +207,16 @@ uint16 Zone::height() const {
|
||||
return _bottom - _top;
|
||||
}
|
||||
|
||||
Dialogue::Dialogue() {
|
||||
memset(_questions, 0, sizeof(_questions));
|
||||
}
|
||||
|
||||
Dialogue::~Dialogue() {
|
||||
for (int i = 0; i < NUM_QUESTIONS; i++) {
|
||||
delete _questions[i];
|
||||
}
|
||||
}
|
||||
|
||||
Answer::Answer() {
|
||||
_text = NULL;
|
||||
_mood = 0;
|
||||
|
@ -181,6 +181,9 @@ struct Question {
|
||||
|
||||
struct Dialogue {
|
||||
Question *_questions[NUM_QUESTIONS];
|
||||
|
||||
Dialogue();
|
||||
~Dialogue();
|
||||
};
|
||||
|
||||
struct GetData { // size = 24
|
||||
|
Loading…
x
Reference in New Issue
Block a user