From a7d9e97a5e17ea6e690f9fca86c4b76f3d102cd9 Mon Sep 17 00:00:00 2001 From: Chaskiel Grundman Date: Tue, 12 Jun 2012 21:42:02 -0400 Subject: Initialize notice objects memset new notice objects in subscr.c (really needed now since all ZFormat* routines require z_num_hdr_fields to be valid or 0.) --- server/subscr.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/server/subscr.c b/server/subscr.c index 7c5099b..4328056 100644 --- a/server/subscr.c +++ b/server/subscr.c @@ -957,6 +957,7 @@ subscr_unsub_sendit(Client *who, list[1] = subs->dest.inst->string; list[2] = ""; + memset(&unotice, 0, sizeof(unotice)); unotice.z_class = ZEPHYR_CTL_CLASS; unotice.z_class_inst = ZEPHYR_CTL_REALM; unotice.z_opcode = REALM_UNSUBSCRIBE; @@ -1050,6 +1051,7 @@ subscr_realm_subs(ZRealm *realm) text[4] = subs->dest.recip->string; /* format snotice */ + memset (&snotice, 0, sizeof(snotice)); snotice.z_class_inst = ZEPHYR_CTL_REALM; snotice.z_opcode = REALM_REQ_SUBSCRIBE; snotice.z_port = 0; -- cgit v1.2.3