-CHANGES.txt - 03/14/2001
+CHANGES.txt - 03/21/2001
------------------------
CHANGES IN CUPS V1.1.7
encryption.
- Fixed a recursion bug in the scheduler that could
cause cupsd to crash when a printer was removed.
+ - The LPDEST and PRINTER environment variables didn't
+ support instances.
CHANGES IN CUPS V1.1.6-3
/*
- * "$Id: dest.c,v 1.16 2001/01/22 15:03:24 mike Exp $"
+ * "$Id: dest.c,v 1.17 2001/03/21 17:58:11 mike Exp $"
*
* User-defined destination (and option) support for the Common UNIX
* Printing System (CUPS).
cups_dest_t *dest; /* Destination pointer */
const char *home; /* HOME environment variable */
char filename[1024]; /* Local ~/.lpoptions file */
+ const char *defprinter; /* Default printer */
+ char name[1024], /* Copy of printer name */
+ *instance; /* Pointer to instance name */
/*
* Grab the default destination...
*/
- if ((dest = cupsGetDest(cupsGetDefault(), NULL, num_dests, *dests)) != NULL)
- dest->is_default = 1;
+ if ((defprinter = cupsGetDefault()) != NULL)
+ {
+ /*
+ * Grab printer and instance name...
+ */
+
+ strncpy(name, defprinter, sizeof(name) - 1);
+ name[sizeof(name) - 1] = '\0';
+
+ if ((instance = strchr(name, '/')) != NULL)
+ *instance++ = '\0';
+
+ /*
+ * Lookup the printer and instance and make it the default...
+ */
+
+ if ((dest = cupsGetDest(name, instance, num_dests, *dests)) != NULL)
+ dest->is_default = 1;
+ }
/*
* Load the /etc/cups/lpoptions and ~/.lpoptions files...
/*
- * End of "$Id: dest.c,v 1.16 2001/01/22 15:03:24 mike Exp $".
+ * End of "$Id: dest.c,v 1.17 2001/03/21 17:58:11 mike Exp $".
*/
/*
- * "$Id: emit.c,v 1.22 2001/03/02 13:42:19 mike Exp $"
+ * "$Id: emit.c,v 1.23 2001/03/21 17:58:12 mike Exp $"
*
* PPD code emission routines for the Common UNIX Printing System (CUPS).
*
ppdEmit(ppd, stdout, PPD_ORDER_JCL);
fputs(ppd->jcl_ps, stdout);
+
+ return (0);
}
/*
- * End of "$Id: emit.c,v 1.22 2001/03/02 13:42:19 mike Exp $".
+ * End of "$Id: emit.c,v 1.23 2001/03/21 17:58:12 mike Exp $".
*/