]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Protect against NULL collection values (<rdar://problem/17903871>)
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Thu, 2 Oct 2014 18:40:12 +0000 (18:40 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Thu, 2 Oct 2014 18:40:12 +0000 (18:40 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@12193 a1ca3aef-8c08-0410-bb20-df032aa958be

cups/ipp-support.c

index 895e6fc430d59b9fb47da6b923f6deb068d16ddb..1964ad00b8bc0148733f1f04a74436be4411f110 100644 (file)
@@ -2223,6 +2223,14 @@ ipp_col_string(ipp_t  *col,              /* I - Collection attribute */
   ipp_attribute_t      *attr;          /* Current member attribute */
 
 
+  if (!col)
+  {
+    if (buffer)
+      *buffer = '\0';
+
+    return (0);
+  }
+
   bufptr = buffer;
   bufend = buffer + bufsize - 1;