/*
- * "$Id: ipp-var.c,v 1.23.2.2 2002/03/28 13:48:10 mike Exp $"
+ * "$Id: ipp-var.c,v 1.23.2.3 2002/04/08 16:28:59 mike Exp $"
*
* IPP variable routines for the Common UNIX Printing System (CUPS).
*
* Map localhost access to localhost and local port...
*/
- if ((strcasecmp(hostname, server) == 0 ||
- strcasecmp(hostname, "localhost") == 0) &&
- (strcmp(getenv("REMOTE_HOST"), "127.0.0.1") == 0 ||
- strcmp(getenv("REMOTE_HOST"), "localhost") == 0 ||
- strcmp(getenv("REMOTE_HOST"), server) == 0))
+ if (strcasecmp(hostname, server) == 0)
{
/*
* Make URI relative to the current server...
/*
- * End of "$Id: ipp-var.c,v 1.23.2.2 2002/03/28 13:48:10 mike Exp $".
+ * End of "$Id: ipp-var.c,v 1.23.2.3 2002/04/08 16:28:59 mike Exp $".
*/
/*
- * "$Id: printers.c,v 1.21.2.3 2002/03/22 15:47:18 mike Exp $"
+ * "$Id: printers.c,v 1.21.2.4 2002/04/08 16:28:59 mike Exp $"
*
* Printer status CGI for the Common UNIX Printing System (CUPS).
*
ippSetServerVersion();
printer = argv[0];
- if (strcmp(printer, "/") == 0 || strcmp(printer, "printers.cgi") == 0)
+ if (strcmp(printer, "/") == 0 || strstr(printer, "printers.cgi") != NULL)
{
printer = NULL;
cgiSetVariable("TITLE", cupsLangString(language, CUPS_MSG_PRINTER));
/*
- * End of "$Id: printers.c,v 1.21.2.3 2002/03/22 15:47:18 mike Exp $".
+ * End of "$Id: printers.c,v 1.21.2.4 2002/04/08 16:28:59 mike Exp $".
*/
/*
- * "$Id: client.c,v 1.91.2.6 2002/01/23 17:32:12 mike Exp $"
+ * "$Id: client.c,v 1.91.2.7 2002/04/08 16:28:59 mike Exp $"
*
* Client routines for the Common UNIX Printing System (CUPS) scheduler.
*
setgroups(0, NULL);
/*
- * Update stdin/stdout...
+ * Update stdin/stdout/stderr...
*/
if (infile)
if (dup(fds[1]) < 0)
exit(errno);
+ close(2);
+ open("/dev/null", O_WRONLY);
+
/*
* Close extra file descriptors...
*/
/*
- * End of "$Id: client.c,v 1.91.2.6 2002/01/23 17:32:12 mike Exp $".
+ * End of "$Id: client.c,v 1.91.2.7 2002/04/08 16:28:59 mike Exp $".
*/