diff options
Diffstat (limited to 'engines/sci/vocabulary.cpp')
-rw-r--r-- | engines/sci/vocabulary.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/sci/vocabulary.cpp b/engines/sci/vocabulary.cpp index cfac4b0ebf..96b01b4c38 100644 --- a/engines/sci/vocabulary.cpp +++ b/engines/sci/vocabulary.cpp @@ -141,7 +141,8 @@ bool vocab_get_opcodes(ResourceManager *resmgr, Common::Array<opcode> &o) { int offset = READ_LE_UINT16(r->data + 2 + i * 2); int len = READ_LE_UINT16(r->data + offset) - 2; o[i].type = READ_LE_UINT16(r->data + offset + 2); - o[i].name = Common::String((char *)r->data + offset + 4, len); + // QFG3 has empty opcodes + o[i].name = len > 0 ? Common::String((char *)r->data + offset + 4, len) : "Dummy"; #if 1 //def VOCABULARY_DEBUG printf("Opcode %02X: %s, %d\n", i, o[i].name.c_str(), o[i].type); #endif |