diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/titanic/support/font.cpp | 2 | ||||
-rw-r--r-- | engines/titanic/true_talk/tt_parser.cpp | 6 | ||||
-rw-r--r-- | engines/titanic/true_talk/tt_vocab.cpp | 1 |
3 files changed, 5 insertions, 4 deletions
diff --git a/engines/titanic/support/font.cpp b/engines/titanic/support/font.cpp index 7bcac9ba08..b91a7ec728 100644 --- a/engines/titanic/support/font.cpp +++ b/engines/titanic/support/font.cpp @@ -90,7 +90,7 @@ int STFont::getTextBounds(const CString &str, int maxWidth, Point *sizeOut) cons strP += 4; } else { if (*strP == ' ') { - // Check fo rline wrapping + // Check for line wrapping checkLineWrap(textSize, maxWidth, strP); } diff --git a/engines/titanic/true_talk/tt_parser.cpp b/engines/titanic/true_talk/tt_parser.cpp index f69c0c7c8f..1045416397 100644 --- a/engines/titanic/true_talk/tt_parser.cpp +++ b/engines/titanic/true_talk/tt_parser.cpp @@ -499,8 +499,10 @@ int TTparser::findFrames(TTsentence *sentence) { for (TTword *currP = word; currP && status <= 1; currP = currP->_nextP) status = processRequests(currP); - word->deleteSiblings(); - delete word; + if (word) { + word->deleteSiblings(); + delete word; + } } if (!status) { diff --git a/engines/titanic/true_talk/tt_vocab.cpp b/engines/titanic/true_talk/tt_vocab.cpp index 785f33a470..6748d6535b 100644 --- a/engines/titanic/true_talk/tt_vocab.cpp +++ b/engines/titanic/true_talk/tt_vocab.cpp @@ -552,7 +552,6 @@ TTword *TTvocab::getPrefixedWord(TTstring &str) const { word->_text = str;
}
- delete tempStr;
return word;
}
|