Bug 13395 - print driver upload error code is wrong
Summary: print driver upload error code is wrong
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Printing (show other bugs)
Version: 4.8.0
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-04-20 11:09 UTC by Björn Jacke
Modified: 2018-05-09 07:51 UTC (History)
2 users (show)

See Also:


Attachments
patch to fix the error code (1.07 KB, patch)
2018-04-20 11:09 UTC, Björn Jacke
bjacke: review+
asn: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Björn Jacke 2018-04-20 11:09:29 UTC
Created attachment 14160 [details]
patch to fix the error code

Some print drivers inf files are broken and cause driver installation to fail
on Samba servers. Windows returns WERR_APP_INIT_FAILURE in that case, we should
do the same. Windows machines are less unlucky with that.

typical patterns in the log files then:

../source3/printing/nt_printing.c:949(move_driver_file_to_download_area)
  move_driver_file_to_download_area: Unable to rename [x64/universalxp] to [x64/3/UNIVERSALXP]: NT_STATUS_OBJECT_NAME_NOT_FOUND

../librpc/ndr/ndr.c:282(ndr_print_function_debug)
       spoolss_AddPrinterDriverEx: struct spoolss_AddPrinterDriverEx
          out: struct spoolss_AddPrinterDriverEx
              result                   : WERR_ACCESS_DENIED

Attached patch makes us return the same error as Windows does.
Comment 1 Björn Jacke 2018-04-25 13:15:35 UTC
in master with 35f2afe411a3b22fb1befadb3bee8da1bc14753c

Karo: can you cherry-pick this also to the supported release branches, please?
Comment 2 Karolin Seeger 2018-05-07 07:14:46 UTC
(In reply to Björn Jacke from comment #1)
Pushed to autobuild-v4-[8,7]-test.
Comment 3 Karolin Seeger 2018-05-09 07:51:16 UTC
(In reply to Karolin Seeger from comment #2)
Pushed to both branches.
Closing out bug report.

Thanks!