--- kdeprint/cups/cupsdconf2/cups-util.c.orig	2007-09-18 12:37:40.000000000 -0400
+++ kdeprint/cups/cupsdconf2/cups-util.c	2007-09-18 12:41:31.000000000 -0400
@@ -108,7 +108,8 @@
       * See if we should retry the current digest password...
       */
 
-      if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0 ||
+      if (strncmp(httpGetField (cups_server, HTTP_FIELD_WWW_AUTHENTICATE),
+		  "Basic", 5) == 0 |
           digest_tries > 1 || !pwdstring[0])
       {
        /*
@@ -116,7 +117,7 @@
 	*/
 
 	snprintf(prompt, sizeof(prompt), "Password for %s on %s? ", cupsUser(),
-        	 cups_server->hostname);
+        	 cupsServer());
 
         if ((password = cupsGetPassword(prompt)) == NULL)
 	  break;
@@ -135,7 +136,8 @@
       * Got a password; encode it for the server...
       */
 
-      if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0)
+      if (strncmp(httpGetField (cups_server, HTTP_FIELD_WWW_AUTHENTICATE),
+		  "Basic", 5) == 0)
       {
        /*
 	* Basic authentication...
@@ -334,7 +336,8 @@
       * See if we should retry the current digest password...
       */
 
-      if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0 ||
+      if (strncmp(httpGetField (cups_server, HTTP_FIELD_WWW_AUTHENTICATE),
+		  "Basic", 5) == 0 |
           digest_tries > 1 || !pwdstring[0])
       {
        /*
@@ -342,7 +345,7 @@
 	*/
 
 	snprintf(prompt, sizeof(prompt), "Password for %s on %s? ", cupsUser(),
-        	 cups_server->hostname);
+        	 cupsServer());
 
         if ((password = cupsGetPassword(prompt)) == NULL)
 	  break;
@@ -361,7 +364,8 @@
       * Got a password; encode it for the server...
       */
 
-      if (strncmp(cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE], "Basic", 5) == 0)
+      if (strncmp(httpGetField (cups_server, HTTP_FIELD_WWW_AUTHENTICATE),
+		  "Basic", 5) == 0)
       {
        /*
 	* Basic authentication...
