/*
- * "$Id: server.c 4830 2005-11-12 03:27:16Z mike $"
+ * "$Id: server.c 4993 2006-01-26 19:27:40Z mike $"
*
* Server start/stop routines for the Common UNIX Printing System (CUPS).
*
#include <cups/http-private.h>
#include "cupsd.h"
#include <grp.h>
+#ifdef HAVE_NOTIFY_H
+# include <notify.h>
+#endif /* HAVE_NOTIFY_H */
/*
FD_SET(CGIPipes[0], InputSet);
}
+ /*
+ * Mark that the server has started and printers and jobs may be changed...
+ */
+
+ LastEvent = CUPSD_EVENT_PRINTER_CHANGED | CUPSD_EVENT_JOB_STATE_CHANGED |
+ CUPSD_EVENT_SERVER_STARTED;
+ LastEventTime = 0;
+
started = 1;
}
PageFile = NULL;
}
+#ifdef HAVE_NOTIFY_POST
+ /*
+ * Send one last notification as the server shuts down.
+ */
+
+ cupsdLogMessage(CUPSD_LOG_DEBUG,
+ "notify_post(\"com.apple.printerListChange\") last");
+ notify_post("com.apple.printerListChange");
+#endif /* HAVE_NOTIFY_POST */
+
started = 0;
}
/*
- * End of "$Id: server.c 4830 2005-11-12 03:27:16Z mike $".
+ * End of "$Id: server.c 4993 2006-01-26 19:27:40Z mike $".
*/