Martin-Éric Racine wrote:

> Looking back at the original bug report that prompted this, I guess
> that yes, a mere Suggests ought to be enough.

Thanks, both.

FWIW here's a rough patch vaguely approximating an implementation of
the other suggestion from that report.  (Completely untested, though.)

In case anyone cares, this change is by me and I place it in the
public domain (or equivalently license it).  You may freely use,
modify, distribute, and relicense it.

=== modified file 'cups/adminutil.c'
--- cups/adminutil.c    2011-03-16 13:49:12 +0000
+++ cups/adminutil.c    2011-03-16 14:14:09 +0000
@@ -482,6 +482,23 @@
             ppd, dest, cg->cups_datadir, cg->cups_datadir,
             cg->cups_datadir, cg->cups_datadir);
 
+    {
+      char buf[1024];
+      if (!cupsFileFind("smbclient", getenv("PATH"), 1, buf, sizeof(buf)))
+      {
+        strlcpy(message,
+                _cupsLangString(language,
+                               _("Unable to copy Windows 2000 printer "
+                                 "driver files: smbclient not found!"),
+                sizeof(message)));
+        _cupsSetError(IPP_INTERNAL_ERROR, message, 0);
+        if (logfile)
+          _cupsLangPrintf(logfile, "%s\n", message);
+        unlink(authfile);
+        return (0);
+      }
+    }
+
     if ((status = do_samba_command("smbclient", address, subcmd,
                                    authfile, logfile)) != 0)
     {
-- 



--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to