]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Mirror fixes from trunk.
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Wed, 5 Mar 2014 20:01:48 +0000 (20:01 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Wed, 5 Mar 2014 20:01:48 +0000 (20:01 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11684 a1ca3aef-8c08-0410-bb20-df032aa958be

CHANGES.txt
config-scripts/cups-compiler.m4
cups/request.c
scheduler/policy.c

index 8f1e60f4c816a849667ef46961dc32caa9c71469..dc720209a0c8edbfbb5de03de1fba5c80fe14a19 100644 (file)
@@ -8,6 +8,9 @@ CHANGES IN CUPS V1.7.2
        - Documentation fixes (STR #3259, STR #4346)
        - Fixed the Japanese localization (STR #4385)
        - Added a German localization (STR #4363)
+       - Updated Linux "relro" support (STR #4349)
+       - cupsDoIORequest could miss the server status, causing failed lpadmin
+         and other administrative commands (STR #4386)
        - cupsEnumDests didn't always call the callback function (STR #4380)
        - "lp -i job-id -H hold" did not work (STR #nnn)
        - CUPS didn't compile on older platforms (STR #4338)
index 252f2aa25408398f01f9fa6b1d075616af33f61c..19a08f8db647901d3a18da5b92f09ef256410dc5 100644 (file)
@@ -1,16 +1,16 @@
 dnl
 dnl "$Id: cups-compiler.m4 7871 2008-08-27 21:12:43Z mike $"
 dnl
-dnl   Compiler stuff for CUPS.
+dnl Compiler stuff for CUPS.
 dnl
-dnl   Copyright 2007-2013 by Apple Inc.
-dnl   Copyright 1997-2007 by Easy Software Products, all rights reserved.
+dnl Copyright 2007-2014 by Apple Inc.
+dnl Copyright 1997-2007 by Easy Software Products, all rights reserved.
 dnl
-dnl   These coded instructions, statements, and computer programs are the
-dnl   property of Apple Inc. and are protected by Federal copyright
-dnl   law.  Distribution and use rights are outlined in the file "LICENSE.txt"
-dnl   which should have been included with this file.  If this file is
-dnl   file is missing or damaged, see the license at "http://www.cups.org/".
+dnl These coded instructions, statements, and computer programs are the
+dnl property of Apple Inc. and are protected by Federal copyright
+dnl law.  Distribution and use rights are outlined in the file "LICENSE.txt"
+dnl which should have been included with this file.  If this file is
+dnl file is missing or damaged, see the license at "http://www.cups.org/".
 dnl
 
 dnl Clear the debugging and non-shared library options unless the user asks
@@ -185,7 +185,7 @@ if test -n "$GCC"; then
                        # The -z relro option is provided by the Linux linker command to
                        # make relocatable data read-only.
                        if test x$enable_relro = xyes; then
-                               RELROFLAGS="-Wl,-z,relro"
+                               RELROFLAGS="-Wl,-z,relro,-z,now"
                        fi
                        ;;
        esac
index 0ccb4996560df6001aed910fc94b1a87b76ae729..33fbac906b0ee8f56adb02f42b41c2ecc09e1f54 100644 (file)
@@ -261,7 +261,7 @@ cupsDoIORequest(http_t     *http,   /* I - Connection to server or @code CUPS_HTTP
     * Get the server's response...
     */
 
-    if (status != HTTP_STATUS_ERROR)
+    if (status <= HTTP_STATUS_CONTINUE)
     {
       response = cupsGetResponse(http, resource);
       status   = httpGetStatus(http);
index 466067036e42e51781105055b9b425b6e7cffd5b..0f9eebc1b39b2b0f47d5752ba56f9f437fabe2f1 100644 (file)
@@ -1,32 +1,16 @@
 /*
  * "$Id$"
  *
- *   Policy routines for the CUPS scheduler.
+ * Policy routines for the CUPS scheduler.
  *
- *   Copyright 2007-2011 by Apple Inc.
- *   Copyright 1997-2006 by Easy Software Products, all rights reserved.
+ * Copyright 2007-2011, 2014 by Apple Inc.
+ * Copyright 1997-2006 by Easy Software Products, all rights reserved.
  *
- *   These coded instructions, statements, and computer programs are the
- *   property of Apple Inc. and are protected by Federal copyright
- *   law.  Distribution and use rights are outlined in the file "LICENSE.txt"
- *   which should have been included with this file.  If this file is
- *   file is missing or damaged, see the license at "http://www.cups.org/".
- *
- * Contents:
- *
- *   AddPolicy()              - Add a policy to the system.
- *   cupsdAddPolicyOp()       - Add an operation to a policy.
- *   cupsdCheckPolicy()       - Check the IPP operation and username against a
- *                              policy.
- *   cupsdDeleteAllPolicies() - Delete all policies in memory.
- *   cupsdFindPolicy()        - Find a named policy.
- *   cupsdFindPolicyOp()      - Find a policy operation.
- *   cupsdGetPrivateAttrs()   - Get the private attributes for the current
- *                              request.
- *   compare_ops()            - Compare two operations.
- *   compare_policies()       - Compare two policies.
- *   free_policy()            - Free the memory used by a policy.
- *   hash_op()                - Generate a lookup hash for the operation.
+ * These coded instructions, statements, and computer programs are the
+ * property of Apple Inc. and are protected by Federal copyright
+ * law.  Distribution and use rights are outlined in the file "LICENSE.txt"
+ * which should have been included with this file.  If this file is
+ * file is missing or damaged, see the license at "http://www.cups.org/".
  */
 
 /*
@@ -48,7 +32,7 @@ static int    hash_op(cupsd_location_t *op);
 
 
 /*
- * 'AddPolicy()' - Add a policy to the system.
+ * 'cupsdAddPolicy()' - Add a policy to the system.
  */
 
 cupsd_policy_t *                       /* O - Policy */
@@ -136,7 +120,7 @@ cupsdCheckPolicy(cupsd_policy_t *p, /* I - Policy */
 
   if (!p || !con)
   {
-    cupsdLogMessage(CUPSD_LOG_CRIT, "cupsdCheckPolicy: p=%p, con=%p!", p, con);
+    cupsdLogMessage(CUPSD_LOG_CRIT, "cupsdCheckPolicy: p=%p, con=%p.", p, con);
 
     return ((http_status_t)0);
   }
@@ -147,7 +131,7 @@ cupsdCheckPolicy(cupsd_policy_t *p, /* I - Policy */
 
   if ((po = cupsdFindPolicyOp(p, con->request->request.op.operation_id)) == NULL)
   {
-    cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdCheckPolicy: No matching operation, returning 0!");
+    cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdCheckPolicy: No matching operation, returning 0.");
     return ((http_status_t)0);
   }
 
@@ -263,7 +247,7 @@ cupsdFindPolicyOp(cupsd_policy_t *p,        /* I - Policy */
     return (po);
   }
 
-  cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindPolicyOp: No match found!");
+  cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindPolicyOp: No match found.");
 
   return (NULL);
 }
@@ -296,6 +280,12 @@ cupsdGetPrivateAttrs(
                  con->http.fd, printer, printer ? printer->name : "", owner);
 #endif /* DEBUG */
 
+  if (!policy)
+  {
+    cupsdLogMessage(CUPSD_LOG_CRIT, "cupsdGetPrivateAttrs: policy=%p, con=%p, printer=%p, owner=\"%s\", DefaultPolicyPtr=%p: This should never happen, please report a bug.", policy, con, printer, owner, DefaultPolicyPtr);
+    policy = DefaultPolicyPtr;
+  }
+
  /*
   * Get the access and attributes lists that correspond to the request...
   */