s3-spoolss: Make spoolss_Time_to_time_t public.
authorSimo Sorce <ssorce@redhat.com>
Fri, 7 May 2010 13:26:41 +0000 (09:26 -0400)
committerGünther Deschner <gd@samba.org>
Sun, 9 May 2010 21:33:40 +0000 (23:33 +0200)
Signed-off-by: Günther Deschner <gd@samba.org>
source3/include/proto.h
source3/rpc_client/init_spoolss.c
source3/smbd/lanman.c

index 10c3d14fcb7bdc0d62d255cfcf088daf71224ae4..9199703c0e5d56bd877e998dc28a338970b87196 100644 (file)
@@ -5612,6 +5612,7 @@ WERROR rpccli_spoolss_enumprinterdataex(struct rpc_pipe_client *cli,
 
 bool init_systemtime(struct spoolss_Time *r,
                     struct tm *unixtime);
+time_t spoolss_Time_to_time_t(const struct spoolss_Time *r);
 WERROR pull_spoolss_PrinterData(TALLOC_CTX *mem_ctx,
                                const DATA_BLOB *blob,
                                union spoolss_PrinterData *data,
index 4c105ea3bc10e9d2482ac97011ef6cef4f6b3264..8320d14fe6bbb7ba42f90dc00dd3542bda3e19b4 100644 (file)
@@ -41,6 +41,21 @@ bool init_systemtime(struct spoolss_Time *r,
        return true;
 }
 
+time_t spoolss_Time_to_time_t(const struct spoolss_Time *r)
+{
+       struct tm unixtime;
+
+       unixtime.tm_year        = r->year - 1900;
+       unixtime.tm_mon         = r->month - 1;
+       unixtime.tm_wday        = r->day_of_week;
+       unixtime.tm_mday        = r->day;
+       unixtime.tm_hour        = r->hour;
+       unixtime.tm_min         = r->minute;
+       unixtime.tm_sec         = r->second;
+
+       return mktime(&unixtime);
+}
+
 /*******************************************************************
  ********************************************************************/
 
index 101fad9dbb13e8d437ec050e6df658ff6ffe003f..6fdad2cb132ba4e77e889837fbabaf1d4117c294 100644 (file)
@@ -533,21 +533,6 @@ static int printq_spoolss_status(int v)
        return RAP_QUEUE_STATUS_ERROR;
 }
 
-static time_t spoolss_Time_to_time_t(const struct spoolss_Time *r)
-{
-       struct tm unixtime;
-
-       unixtime.tm_year        = r->year - 1900;
-       unixtime.tm_mon         = r->month - 1;
-       unixtime.tm_wday        = r->day_of_week;
-       unixtime.tm_mday        = r->day;
-       unixtime.tm_hour        = r->hour;
-       unixtime.tm_min         = r->minute;
-       unixtime.tm_sec         = r->second;
-
-       return mktime(&unixtime);
-}
-
 static void fill_spoolss_printjob_info(int uLevel,
                                       struct pack_desc *desc,
                                       struct spoolss_JobInfo2 *info2,