Use ef_blank() when extending treaty, loan, comm and trade file
Only treaty extension initialized ef_type and uid properly. None of them zeroed unused members and holes in the struct. comm and trade extension called ef_extend(), which had no effect, so remove that.
This commit is contained in:
parent
93d8c53f21
commit
2da8d0c796
3 changed files with 6 additions and 8 deletions
|
@ -143,9 +143,8 @@ sell(void)
|
|||
if (comm.com_owner == 0)
|
||||
break;
|
||||
}
|
||||
if (getcomm(ii, &comm) == 0)
|
||||
ef_extend(EF_COMM, 1);
|
||||
(void)time(&now);
|
||||
ef_blank(EF_COMM, ii, &comm);
|
||||
comm.com_type = ip->i_uid;
|
||||
comm.com_owner = player->cnum;
|
||||
comm.com_price = price;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue