]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - cgi-bin/ipp-var.c
Merge changes from CUPS 1.4svn-r7282.
[thirdparty/cups.git] / cgi-bin / ipp-var.c
index 8f86191274172060ccf59053d67c01554acbd627..c1703e101afed0b8e4d7bb7ffbf9e34a48a63b40 100644 (file)
@@ -525,8 +525,7 @@ cgiPrintTestPage(http_t     *http,  /* I - Connection to server */
   * See who is logged in...
   */
 
-  if ((user = getenv("REMOTE_USER")) == NULL)
-    user = "guest";
+  user = getenv("REMOTE_USER");
 
  /*
   * Locate the test page file...
@@ -564,8 +563,9 @@ cgiPrintTestPage(http_t     *http,  /* I - Connection to server */
   ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri",
                NULL, uri);
 
-  ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
-               "requesting-user-name", NULL, user);
+  if (user)
+    ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
+                "requesting-user-name", NULL, user);
 
   ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name",
                NULL, "Test Page");