* fill a notify_info_data with the servername
********************************************************************/
-static void spoolss_notify_server_name(int snum,
+static void spoolss_notify_server_name(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the printername (not including the servername).
********************************************************************/
-static void spoolss_notify_printer_name(int snum,
+static void spoolss_notify_printer_name(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the servicename
********************************************************************/
-static void spoolss_notify_share_name(int snum,
+static void spoolss_notify_share_name(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the port name
********************************************************************/
-static void spoolss_notify_port_name(int snum,
+static void spoolss_notify_port_name(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* but it doesn't exist, have to see what to do
********************************************************************/
-static void spoolss_notify_driver_name(int snum,
+static void spoolss_notify_driver_name(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the comment
********************************************************************/
-static void spoolss_notify_comment(int snum,
+static void spoolss_notify_comment(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* location = "Room 1, floor 2, building 3"
********************************************************************/
-static void spoolss_notify_location(int snum,
+static void spoolss_notify_location(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* jfm:xxxx don't to it for know but that's a real problem !!!
********************************************************************/
-static void spoolss_notify_devmode(int snum,
+static void spoolss_notify_devmode(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the separator file name
********************************************************************/
-static void spoolss_notify_sepfile(int snum,
+static void spoolss_notify_sepfile(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* jfm:xxxx return always winprint to indicate we don't do anything to it
********************************************************************/
-static void spoolss_notify_print_processor(int snum,
+static void spoolss_notify_print_processor(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* jfm:xxxx send an empty string
********************************************************************/
-static void spoolss_notify_parameters(int snum,
+static void spoolss_notify_parameters(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* jfm:xxxx always send RAW as data type
********************************************************************/
-static void spoolss_notify_datatype(int snum,
+static void spoolss_notify_datatype(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* have to implement security before !
********************************************************************/
-static void spoolss_notify_security_desc(int snum,
+static void spoolss_notify_security_desc(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* jfm:xxxx a samba printer is always shared
********************************************************************/
-static void spoolss_notify_attributes(int snum,
+static void spoolss_notify_attributes(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the priority
********************************************************************/
-static void spoolss_notify_priority(int snum,
+static void spoolss_notify_priority(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the default priority
********************************************************************/
-static void spoolss_notify_default_priority(int snum,
+static void spoolss_notify_default_priority(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the start time
********************************************************************/
-static void spoolss_notify_start_time(int snum,
+static void spoolss_notify_start_time(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the until time
********************************************************************/
-static void spoolss_notify_until_time(int snum,
+static void spoolss_notify_until_time(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with the status
********************************************************************/
-static void spoolss_notify_status(int snum,
+static void spoolss_notify_status(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
{
print_status_struct status;
- print_queue_length(server_messaging_context(), snum, &status);
+ print_queue_length(msg_ctx, snum, &status);
SETUP_SPOOLSS_NOTIFY_DATA_INTEGER(data, status.status);
}
* fill a notify_info_data with the number of jobs queued
********************************************************************/
-static void spoolss_notify_cjobs(int snum,
+static void spoolss_notify_cjobs(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
TALLOC_CTX *mem_ctx)
{
SETUP_SPOOLSS_NOTIFY_DATA_INTEGER(
- data, print_queue_length(server_messaging_context(), snum,
- NULL));
+ data, print_queue_length(msg_ctx, snum, NULL));
}
/*******************************************************************
* fill a notify_info_data with the average ppm
********************************************************************/
-static void spoolss_notify_average_ppm(int snum,
+static void spoolss_notify_average_ppm(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with username
********************************************************************/
-static void spoolss_notify_username(int snum,
+static void spoolss_notify_username(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with job status
********************************************************************/
-static void spoolss_notify_job_status(int snum,
+static void spoolss_notify_job_status(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with job name
********************************************************************/
-static void spoolss_notify_job_name(int snum,
+static void spoolss_notify_job_name(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with job status
********************************************************************/
-static void spoolss_notify_job_status_string(int snum,
+static void spoolss_notify_job_status_string(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with job time
********************************************************************/
-static void spoolss_notify_job_time(int snum,
+static void spoolss_notify_job_time(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
* fill a notify_info_data with job size
********************************************************************/
-static void spoolss_notify_job_size(int snum,
+static void spoolss_notify_job_size(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
/*******************************************************************
* fill a notify_info_data with page info
********************************************************************/
-static void spoolss_notify_total_pages(int snum,
+static void spoolss_notify_total_pages(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
/*******************************************************************
* fill a notify_info_data with pages printed info.
********************************************************************/
-static void spoolss_notify_pages_printed(int snum,
+static void spoolss_notify_pages_printed(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
Fill a notify_info_data with job position.
********************************************************************/
-static void spoolss_notify_job_position(int snum,
+static void spoolss_notify_job_position(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
Fill a notify_info_data with submitted time.
********************************************************************/
-static void spoolss_notify_submitted_time(int snum,
+static void spoolss_notify_submitted_time(struct messaging_context *msg_ctx,
+ int snum,
struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
uint16_t field;
const char *name;
enum spoolss_NotifyTable variable_type;
- void (*fn) (int snum, struct spoolss_Notify *data,
+ void (*fn) (struct messaging_context *msg_ctx,
+ int snum, struct spoolss_Notify *data,
print_queue_struct *queue,
struct spoolss_PrinterInfo2 *pinfo2,
TALLOC_CTX *mem_ctx);
notify_info_data_table[j].name, snum,
pinfo2->printername));
- notify_info_data_table[j].fn(snum, current_data, queue,
+ notify_info_data_table[j].fn(server_messaging_context(),
+ snum, current_data, queue,
pinfo2, mem_ctx);
info->count++;
current_data=&(info->notifies[info->count]);
construct_info_data(current_data, type, field, id);
- notify_info_data_table[j].fn(snum, current_data, queue,
+ notify_info_data_table[j].fn(server_messaging_context(),
+ snum, current_data, queue,
pinfo2, mem_ctx);
info->count++;
}