diff -ur ScummVM-cvs20030311/scummvm/scumm/string.cpp ScummVM-cvs20030311+hack/scummvm/scumm/string.cpp
old
|
new
|
|
970 | 970 | } |
971 | 971 | } |
972 | 972 | |
| 973 | // If the string has a translation ID but no translation was found, |
| 974 | // fall back on the untranslated string. |
| 975 | |
973 | 976 | if (text[0] == '/') { |
974 | 977 | byte *pointer = (byte *)strchr((char *)text + 1, '/'); |
975 | 978 | if (pointer != NULL) { |
976 | 979 | pointer++; |
977 | | int l = 0; |
978 | | while (*pointer != '/' && *pointer != 0xff && *pointer != 0) { |
979 | | trans_buff[l++] = *pointer++; |
980 | | } |
981 | | trans_buff[l] = '\0'; |
| 980 | memcpy(trans_buff, pointer, resStrLen(pointer) + 1); |
| 981 | return; |
982 | 982 | } |
983 | | else |
984 | | trans_buff[0] = '\0'; |
985 | | return; |
986 | 983 | } |
987 | 984 | |
| 985 | // As a last resort, use the original string. |
| 986 | |
988 | 987 | memcpy(trans_buff, text, resStrLen(text) + 1); |
989 | 988 | } |
990 | 989 | |