Return NULL if n < 0 on line 886, for whatever reason on FreeBSD this falls

through exception handling and causes and abort().

Originally committed to SVN as r2743.
This commit is contained in:
Amar Takhar 2009-02-19 23:58:06 +00:00
parent 1426f4f67b
commit 761f044526

View file

@ -883,6 +883,7 @@ void BaseGrid::SetColumnWidths() {
// Gets dialogue from map
AssDialogue *BaseGrid::GetDialogue(int n) {
try {
if (n < 0) return NULL;
AssEntry *e = *diagMap.at(n);
if (e->GetType() != ENTRY_DIALOGUE) return NULL;
return AssEntry::GetAsDialogue(e);