/*
- * "$Id: options.c,v 1.21.2.8 2003/01/07 18:26:28 mike Exp $"
+ * "$Id: options.c,v 1.21.2.9 2003/03/21 18:07:34 mike Exp $"
*
* Option routines for the Common UNIX Printing System (CUPS).
*
value = ptr;
while (*ptr != '\'' && *ptr != '\0')
+ {
+ if (*ptr == '\\')
+ strcpy(ptr, ptr + 1);
+
ptr ++;
+ }
if (*ptr != '\0')
*ptr++ = '\0';
value = ptr;
while (*ptr != '\"' && *ptr != '\0')
+ {
+ if (*ptr == '\\')
+ strcpy(ptr, ptr + 1);
+
ptr ++;
+ }
+
+ if (*ptr != '\0')
+ *ptr++ = '\0';
+ }
+ else if (*ptr == '{')
+ {
+ /*
+ * Collection value...
+ */
+
+ int depth;
+
+ value = ptr;
+
+ for (depth = 1; *ptr; ptr ++)
+ if (*ptr == '{')
+ depth ++;
+ else if (*ptr == '}')
+ {
+ depth --;
+ if (!depth)
+ {
+ ptr ++;
+
+ if (*ptr != ',')
+ break;
+ }
+ }
+ else if (*ptr == '\\')
+ strcpy(ptr, ptr + 1);
if (*ptr != '\0')
*ptr++ = '\0';
value = ptr;
while (!isspace(*ptr) && *ptr != '\0')
- ptr ++;
+ {
+ if (*ptr == '\\')
+ strcpy(ptr, ptr + 1);
+
+ ptr ++;
+ }
}
/*
/*
- * End of "$Id: options.c,v 1.21.2.8 2003/01/07 18:26:28 mike Exp $".
+ * End of "$Id: options.c,v 1.21.2.9 2003/03/21 18:07:34 mike Exp $".
*/
/*
- * "$Id: testipp.c,v 1.1 2003/03/20 02:45:22 mike Exp $"
+ * "$Id: testipp.c,v 1.1.2.1 2003/03/21 18:07:34 mike Exp $"
*
* IPP test program for the Common UNIX Printing System (CUPS).
*
/*
- * End of "$Id: testipp.c,v 1.1 2003/03/20 02:45:22 mike Exp $".
+ * End of "$Id: testipp.c,v 1.1.2.1 2003/03/21 18:07:34 mike Exp $".
*/