/* This file is part of the Project Athena Zephyr Notification System. * It contains source for the ZSendPacket function. * Created by: Robert French * Copyright (c) 1987,1991 by the Massachusetts Institute of Technology. * For copying and distribution information, see the file static int wait_for_hmack(ZNotice_t *notice, void *uid); Code_t ZSendPacket(packet, len, waitforack) ZNotice_t notice, acknotice; if ((retval = ZOpenPort((unsigned short *)0)) != ZERR_NONE) if (sendto(ZGetFD(), packet, len, 0, (struct sockaddr *)&dest, if ((retval = ZParseNotice(packet, len, ¬ice)) != ZERR_NONE) retval = Z_WaitForNotice (&acknotice, wait_for_hmack, ¬ice.z_uid, ZFreeNotice (&acknotice); static int wait_for_hmack(ZNotice_t *notice, void *uid) return (notice->z_kind == HMACK && ZCompareUID(¬ice->z_uid, (ZUnique_Id_t *)uid));