forked from github/server
eliminate leak from alliance.test
This commit is contained in:
parent
9499919387
commit
4115bff79b
1 changed files with 6 additions and 8 deletions
|
@ -288,14 +288,12 @@ static void perform_join(void)
|
||||||
static syntaxtree * build_syntax(void) {
|
static syntaxtree * build_syntax(void) {
|
||||||
syntaxtree *slang, *stree = stree_create();
|
syntaxtree *slang, *stree = stree_create();
|
||||||
for (slang = stree; slang; slang = slang->next) {
|
for (slang = stree; slang; slang = slang->next) {
|
||||||
struct tnode *leaf = 0;
|
stree_add(slang, LOC(slang->lang, alliance_kwd[ALLIANCE_KICK]), &cmd_kick);
|
||||||
add_command(&leaf, LOC(slang->lang, alliance_kwd[ALLIANCE_KICK]), &cmd_kick);
|
stree_add(slang, LOC(slang->lang, alliance_kwd[ALLIANCE_LEAVE]), &cmd_leave);
|
||||||
add_command(&leaf, LOC(slang->lang, alliance_kwd[ALLIANCE_LEAVE]), &cmd_leave);
|
stree_add(slang, LOC(slang->lang, alliance_kwd[ALLIANCE_TRANSFER]), &cmd_transfer);
|
||||||
add_command(&leaf, LOC(slang->lang, alliance_kwd[ALLIANCE_TRANSFER]), &cmd_transfer);
|
stree_add(slang, LOC(slang->lang, alliance_kwd[ALLIANCE_NEW]), &cmd_new);
|
||||||
add_command(&leaf, LOC(slang->lang, alliance_kwd[ALLIANCE_NEW]), &cmd_new);
|
stree_add(slang, LOC(slang->lang, alliance_kwd[ALLIANCE_INVITE]), &cmd_invite);
|
||||||
add_command(&leaf, LOC(slang->lang, alliance_kwd[ALLIANCE_INVITE]), &cmd_invite);
|
stree_add(slang, LOC(slang->lang, alliance_kwd[ALLIANCE_JOIN]), &cmd_join);
|
||||||
add_command(&leaf, LOC(slang->lang, alliance_kwd[ALLIANCE_JOIN]), &cmd_join);
|
|
||||||
slang->root = leaf;
|
|
||||||
}
|
}
|
||||||
return stree;
|
return stree;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue