diff options
author | Gerald Carter <jerry@samba.org> | 2003-02-25 20:53:53 +0000 |
---|---|---|
committer | Gerald Carter <jerry@samba.org> | 2003-02-25 20:53:53 +0000 |
commit | 23b3b29eec61860155404333f6e70ebd24b50940 (patch) | |
tree | be9a2981266cc1cce4e9144bb5a77ed0f364a830 /source3/smbd | |
parent | b8fbb3189a8b55ddc87f9b52b1c00d1acbb37e72 (diff) | |
download | samba-23b3b29eec61860155404333f6e70ebd24b50940.tar.gz samba-23b3b29eec61860155404333f6e70ebd24b50940.tar.bz2 samba-23b3b29eec61860155404333f6e70ebd24b50940.zip |
Progress on CR 601
cache the printer_info_2 with the open printer handle.
cache is invalidated on a mod_a_printer() call **on that smbd**.
Yes, this means that the window for admins to step on each other
from different clients just got larger, but since handles a generally
short lived this is probably ok.
(This used to be commit 31272d3b6bb9ec62fd666301c7adfa0c1720a99b)
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/lanman.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c index 25f390be55..98857c6d32 100644 --- a/source3/smbd/lanman.c +++ b/source3/smbd/lanman.c @@ -500,7 +500,7 @@ static BOOL get_driver_name(int snum, pstring drivername) NT_PRINTER_INFO_LEVEL *info = NULL; BOOL in_tdb = False; - get_a_printer (&info, 2, lp_servicename(snum)); + get_a_printer (NULL, &info, 2, lp_servicename(snum)); if (info != NULL) { pstrcpy( drivername, info->info_2->drivername); in_tdb = True; @@ -522,7 +522,7 @@ static void fill_printq_info_52(connection_struct *conn, int snum, NT_PRINTER_DRIVER_INFO_LEVEL driver; NT_PRINTER_INFO_LEVEL *printer = NULL; - if ( !W_ERROR_IS_OK(get_a_printer( &printer, 2, lp_servicename(snum))) ) { + if ( !W_ERROR_IS_OK(get_a_printer( NULL, &printer, 2, lp_servicename(snum))) ) { DEBUG(3,("fill_printq_info_52: Failed to lookup printer [%s]\n", lp_servicename(snum))); goto err; @@ -679,7 +679,7 @@ static int get_printerdrivernumber(int snum) NT_PRINTER_DRIVER_INFO_LEVEL driver; NT_PRINTER_INFO_LEVEL *printer = NULL; - if ( !W_ERROR_IS_OK(get_a_printer( &printer, 2, lp_servicename(snum))) ) { + if ( !W_ERROR_IS_OK(get_a_printer( NULL, &printer, 2, lp_servicename(snum))) ) { DEBUG(3,("get_printerdrivernumber: Failed to lookup printer [%s]\n", lp_servicename(snum))); goto done; |