/*
- * "$Id: bcp.c 6649 2007-07-11 21:46:42Z mike $"
+ * "$Id: bcp.c 10996 2013-05-29 11:51:34Z msweet $"
*
- * TBCP port monitor for the Common UNIX Printing System (CUPS).
+ * TBCP port monitor for CUPS.
*
- * Copyright 2007 by Apple Inc.
+ * Copyright 2007-2010 by Apple Inc.
* Copyright 1993-2006 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
*
* Contents:
*
+ * main() - Main entry...
+ * psgets() - Get a line from a file.
+ * pswrite() - Write data from a file.
*/
/*
* Include necessary headers...
*/
-#include <cups/string.h>
-#include <cups/cups.h>
+#include <cups/cups-private.h>
+#include <cups/ppd.h>
/*
if (argc < 6 || argc > 7)
{
- fputs("ERROR: tbcp job-id user title copies options [file]\n", stderr);
+ _cupsLangPrintf(stderr,
+ _("Usage: %s job-id user title copies options [file]"),
+ argv[0]);
return (1);
}
for (count = bytes; count > 0; count --, buf ++)
switch (*buf)
{
+ case 0x04 : /* CTRL-D */
+ if (bytes == 1)
+ {
+ /*
+ * Don't quote the last CTRL-D...
+ */
+
+ putchar(0x04);
+ break;
+ }
+
case 0x01 : /* CTRL-A */
case 0x03 : /* CTRL-C */
- case 0x04 : /* CTRL-D */
case 0x05 : /* CTRL-E */
case 0x11 : /* CTRL-Q */
case 0x13 : /* CTRL-S */
/*
- * End of "$Id: bcp.c 6649 2007-07-11 21:46:42Z mike $".
+ * End of "$Id: bcp.c 10996 2013-05-29 11:51:34Z msweet $".
*/