(trtstr): New members ef_type and trt_uid.

(do_treaty): Initialize them.
(treaty_ca): New selector uid.
This commit is contained in:
Markus Armbruster 2005-11-01 12:53:43 +00:00
parent ae9e7dad43
commit bbc1ee8eb1
3 changed files with 5 additions and 0 deletions

View file

@ -36,7 +36,9 @@
#define _TREATY_H_
struct trtstr {
short ef_type;
natid trt_cna; /* proposer */
short trt_uid;
natid trt_cnb; /* acceptor */
s_char trt_status; /* treaty status */
s_char trt_fill;

View file

@ -140,6 +140,8 @@ do_treaty(void)
break;
}
}
trty.ef_type = EF_TREATY;
trty.trt_uid = nstr.cur;
trty.trt_acond = ourcond;
trty.trt_bcond = theircond;
trty.trt_status = TS_PROPOSED;

View file

@ -364,6 +364,7 @@ struct castr nchr_ca[] = {
};
struct castr treaty_ca[] = {
{NSC_SHORT, 0, 0, fldoff(trtstr, trt_uid), "uid", EF_BAD},
{NSC_NATID, 0, 0, fldoff(trtstr, trt_cna), "cna", EF_BAD},
{NSC_NATID, 0, 0, fldoff(trtstr, trt_cnb), "cnb", EF_BAD},
{NSC_CHAR, 0, 0, fldoff(trtstr, trt_status), "status", EF_BAD},