mirror of
https://github.com/tbamud/tbamud.git
synced 2026-03-24 05:06:33 +01:00
Fix hedit segfault issue
This commit is contained in:
parent
8371124765
commit
43028a4e38
1 changed files with 6 additions and 3 deletions
|
|
@ -84,12 +84,15 @@ ACMD(do_oasis_hedit)
|
|||
|
||||
OLC_ZNUM(d) = search_help(OLC_STORAGE(d), LVL_IMPL);
|
||||
|
||||
if (help_table[OLC_ZNUM(d)].duplicate) {
|
||||
for (i = 0; i < top_of_helpt; i++)
|
||||
if (help_table[i].duplicate == 0 && help_table[i].entry == help_table[OLC_ZNUM(d)].entry) {
|
||||
/* Only check duplicate chains if we found a real record */
|
||||
if (OLC_ZNUM(d) != NOWHERE && help_table[OLC_ZNUM(d)].duplicate) {
|
||||
for (i = 0; i < top_of_helpt; i++) {
|
||||
if (help_table[i].duplicate == 0 &&
|
||||
help_table[i].entry == help_table[OLC_ZNUM(d)].entry) {
|
||||
OLC_ZNUM(d) = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (OLC_ZNUM(d) == NOWHERE) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue