]>
git.ipfire.org Git - thirdparty/cups.git/blob - backend/betest.c
2 * "$Id: betest.c 177 2006-06-21 00:20:03Z jlovell $"
4 * Backend test program for the Common UNIX Printing System (CUPS).
6 * Copyright 1997-2005 by Easy Software Products, all rights reserved.
8 * These coded instructions, statements, and computer programs are the
9 * property of Easy Software Products and are protected by Federal
10 * copyright law. Distribution and use rights are outlined in the file
11 * "LICENSE" which should have been included with this file. If this
12 * file is missing or damaged please contact Easy Software Products
15 * Attn: CUPS Licensing Information
16 * Easy Software Products
17 * 44141 Airport View Drive, Suite 204
18 * Hollywood, Maryland 20636 USA
20 * Voice: (301) 373-9600
21 * EMail: cups-info@cups.org
22 * WWW: http://www.cups.org
24 * This file is subject to the Apple OS-Developed Software exception.
28 * main() - Run the named backend.
32 * Include necessary headers.
37 #include <cups/string.h>
42 * 'main()' - Run the named backend.
46 * betest device-uri job-id user title copies options [file]
49 int /* O - Exit status */
50 main(int argc
, /* I - Number of command-line arguments (7 or 8) */
51 char *argv
[]) /* I - Command-line arguments */
53 char backend
[255]; /* Method in URI */
56 if (argc
< 7 || argc
> 8)
58 fputs("Usage: betest device-uri job-id user title copies options [file]\n",
64 * Extract the method from the device-uri - that's the program we want to
68 if (sscanf(argv
[1], "%254[^:]", backend
) != 1)
70 fputs("betest: Bad device-uri - no colon!\n", stderr
);
78 execl(backend
, argv
[1], argv
[2], argv
[3], argv
[4], argv
[5], argv
[6], argv
[7],
86 * End of "$Id: betest.c 177 2006-06-21 00:20:03Z jlovell $".