summaryrefslogtreecommitdiff
path: root/source3/printing/notify.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2003-04-02 02:26:01 +0000
committerJeremy Allison <jra@samba.org>2003-04-02 02:26:01 +0000
commitf6f96c2966ee3c96cb8188ce832aa822146de337 (patch)
tree406cd7aa0d204944cbd6a16c9b8c605bbb116c8e /source3/printing/notify.c
parent938982737509745b57152452a7983bed0fb2fd3b (diff)
downloadsamba-f6f96c2966ee3c96cb8188ce832aa822146de337.tar.gz
samba-f6f96c2966ee3c96cb8188ce832aa822146de337.tar.bz2
samba-f6f96c2966ee3c96cb8188ce832aa822146de337.zip
Subtle changes to message handling after ENUMJOBS.
Jeremy. (This used to be commit 48f3bf0ea51b9fd09dfb017870e32ca4a8cc4b8c)
Diffstat (limited to 'source3/printing/notify.c')
-rw-r--r--source3/printing/notify.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source3/printing/notify.c b/source3/printing/notify.c
index 50c5ce39f6..641f951bdd 100644
--- a/source3/printing/notify.c
+++ b/source3/printing/notify.c
@@ -27,6 +27,7 @@ static TALLOC_CTX *send_ctx;
static struct notify_queue {
struct notify_queue *next, *prev;
struct spoolss_notify_msg *msg;
+ struct timeval tv;
char *buf;
size_t buflen;
} *notify_queue_head = NULL;
@@ -81,7 +82,8 @@ again:
len += tdb_pack(buf + len, buflen - len, "f", msg->printer);
- len += tdb_pack(buf + len, buflen - len, "ddddd",
+ len += tdb_pack(buf + len, buflen - len, "ddddddd",
+ (uint32)q->tv.tv_sec, (uint32)q->tv.tv_usec,
msg->type, msg->field, msg->id, msg->len, msg->flags);
/* Pack data */
@@ -259,6 +261,7 @@ in notify_queue\n", msg->type, msg->field, msg->printer));
return;
}
copy_notify2_msg(pnqueue->msg, msg);
+ gettimeofday(&pnqueue->tv, NULL);
pnqueue->buf = NULL;
pnqueue->buflen = 0;