]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - cups/getdevices.c
Merge changes from CUPS 1.5svn-r9062.
[thirdparty/cups.git] / cups / getdevices.c
index 44500d3fcbb81f6bb9df621612627abe76ac1131..a74a593c714f2fb40de372b153a551395cb95824 100644 (file)
@@ -1,9 +1,9 @@
 /*
  * "$Id$"
  *
- *   cupsGetDevices implementation for the Common UNIX Printing System (CUPS).
+ *   cupsGetDevices implementation for CUPS.
  *
- *   Copyright 2008-2009 by Apple Inc.
+ *   Copyright 2008-2010 by Apple Inc.
  *
  *   These coded instructions, statements, and computer programs are the
  *   property of Apple Inc. and are protected by Federal copyright
@@ -22,8 +22,7 @@
  * Include necessary headers...
  */
 
-#include "globals.h"
-#include "debug.h"
+#include "cups-private.h"
 
 
 /*
@@ -35,7 +34,7 @@
  * parameters provide comma-delimited lists of backends to include or omit from
  * the request respectively.
  *
- * @since CUPS 1.4@
+ * @since CUPS 1.4/Mac OS X 10.6@
  */
 
 ipp_status_t                           /* O - Request status - @code IPP_OK@ on success. */
@@ -134,7 +133,10 @@ cupsGetDevices(
        if (!cupsDoAuthentication(http, "POST", "/"))
          httpReconnect(http);
        else
+       {
+         status = HTTP_AUTHORIZATION_CANCELED;
          break;
+       }
       }
 
 #ifdef HAVE_SSL
@@ -255,7 +257,7 @@ cupsGetDevices(
   httpBlocking(http, blocking);
   httpFlush(http);
 
-  if (status == IPP_ERROR)
+  if (status == HTTP_ERROR)
     _cupsSetError(IPP_ERROR, NULL, 0);
   else
   {