#include <sysdep.h>
#ifdef CMU_ZWGCPLUS
#if (!defined(lint) && !defined(SABER))
-static char rcsid_plus_c[] = "$Id: plus.c,v 1.7 1998/08/10 22:54:11 shadow Exp $";
+static const char rcsid_plus_c[] = "$Id: plus.c,v 1.7 1998/08/10 22:54:11 shadow Exp $";
#endif
#include <zephyr/mit-copyright.h>
#include "notice.h"
#include "X_gram.h"
#include "xrevstack.h"
+#include "main.h"
#include "plus.h"
int get_full_names = 0;
static notnode *notlist[HASHSIZE];
TimeNode *timeq_head = NULL;
-TimeNode
-*addtimenode(head, node)
- TimeNode *head;
- TimeNode *node;
+int list_hash_fun(ZNotice_t *notice);
+
+TimeNode *
+addtimenode(TimeNode *head, TimeNode *node)
{
if(head == NULL) {
#ifdef DEBUG_TIMEQUEUE
}
void
-handle_timeq_event(event)
- TimeNode *event;
+handle_timeq_event(TimeNode *event)
{
- char *tmp;
-
char buf[128];
notnode *pt;
int bx = list_hash_fun(event->notice);
}
void
-schedule_event(secs, name, notice)
- long secs;
- char *name;
- ZNotice_t *notice;
+schedule_event(long secs, char *name, ZNotice_t *notice)
{
time_t eventtime = (time(NULL)) + secs;
TimeNode *newnode;
}
void
-free_timenode(node)
- TimeNode *node;
+free_timenode(TimeNode *node)
{
#ifdef DEBUG_TIMEQUEUE
fprintf(stderr, "free_timenode(%s)\n", node->event_name);
/* returns the number of notices destroyed */
int
-destroy_timeq_notice(notice, name)
- ZNotice_t *notice;
- char *name;
+destroy_timeq_notice(ZNotice_t *notice, char *name)
{
TimeNode *curr = timeq_head;
TimeNode *prev = NULL;
}
long
-plus_timequeue_events()
+plus_timequeue_events(void)
{
/* returns number of seconds to the next event or 0L */
/* if there are no events remaining to be processed */
}
void
-plus_set_hname(notice, hname)
- ZNotice_t *notice;
- char *hname;
+plus_set_hname(ZNotice_t *notice, char *hname)
{
notnode *pt;
int bx;
}
void
-plus_queue_notice(notice)
- ZNotice_t *notice;
+plus_queue_notice(ZNotice_t *notice)
{
char *val;
int howlong = 0;
}
int
-list_hash_fun(notice)
- ZNotice_t *notice;
+list_hash_fun(ZNotice_t *notice)
{
int ix;
int res = 0, val = 1, ptval;
/* initialize hash table */
void
-init_noticelist()
+init_noticelist(void)
{
int ix;
}
void
-dump_noticelist()
+dump_noticelist(void)
{
notnode *pt;
int bx;
/* add notice to table. Either generate a new entry, or increment ref count. */
void
-list_add_notice(notice)
- ZNotice_t *notice;
+list_add_notice(ZNotice_t *notice)
{
notnode *pt;
int bx = list_hash_fun(notice);
/* remove notice from table. If refcount reaches 0, return 1; if refcount is
still positive, return 0; if notice not there, return -1. */
int
-list_del_notice(notice)
- ZNotice_t *notice;
+list_del_notice(ZNotice_t *notice)
{
notnode *pt, **ppt;
int bx = list_hash_fun(notice);
}
void
-set_notice_fake(notice, val)
- ZNotice_t *notice;
- int val;
+set_notice_fake(ZNotice_t *notice, int val)
{
notnode *pt;
int bx = list_hash_fun(notice);
}
int
-get_notice_fake(notice)
- ZNotice_t *notice;
+get_notice_fake(ZNotice_t *notice)
{
notnode *pt;
int bx = list_hash_fun(notice);
}
int
-get_list_refcount(notice)
- ZNotice_t *notice;
+get_list_refcount(ZNotice_t *notice)
{
notnode *pt;
int bx = list_hash_fun(notice);
}
/* export a reference to the current notice. */
-char
-*get_stored_notice()
+char *
+get_stored_notice(void)
{
if (!stored_notice)
return NULL;
}
void
-set_stored_notice(notice)
- ZNotice_t *notice;
+set_stored_notice(ZNotice_t *notice)
{
stored_notice = notice;
}
void
-plus_retry_notice(notice, ch, metaflag)
- ZNotice_t *notice;
- char ch;
- int metaflag;
+plus_retry_notice(ZNotice_t *notice, char ch, int metaflag)
{
char buf[128];
char *tmp;