]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - cgi-bin/template.c
Import CUPS 1.4svn-r7226.
[thirdparty/cups.git] / cgi-bin / template.c
index 0d301e11ae2733e4013e321288a7fbe465648de1..661f6395b9d737086ec05cb7fba43fd788e3724b 100644 (file)
@@ -3,7 +3,7 @@
  *
  *   CGI template function.
  *
- *   Copyright 2007 by Apple Inc.
+ *   Copyright 2007-2008 by Apple Inc.
  *   Copyright 1997-2006 by Easy Software Products.
  *
  *   These coded instructions, statements, and computer programs are the
@@ -54,6 +54,13 @@ cgiCopyTemplateFile(FILE       *out, /* I - Output file */
   fprintf(stderr, "DEBUG2: cgiCopyTemplateFile(out=%p, tmpl=\"%s\")\n", out,
           tmpl ? tmpl : "(null)");
 
+ /*
+  * Range check input...
+  */
+
+  if (!tmpl || !out)
+    return;
+
  /*
   * Open the template file...
   */