# requested perm
# fperm -> default permission value for filesOR with the client
# requested perm
-
#
# miscellaneous options [syntax: options:option1,option2]:
# prodos -> make compatible with appleII clients.
/*
- * $Id: lp.c,v 1.14.8.4.2.7 2009-02-03 08:25:00 didg Exp $
+ * $Id: lp.c,v 1.14.8.4.2.8 2009-02-04 22:33:11 didg Exp $
*
* Copyright (c) 1990,1994 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
destlen -= len;
}
}
+ if (!destlen) {
+ /* reach end of buffer, maybe prematurely, give up */
+ return NULL;
+ }
return destbuf;
}
lp_setup_comments(CH_UNIX);
pipe_cmd = pipexlate(printer->p_printer);
+ if (!pipe_cmd) {
+ LOG(log_error, logtype_papd, "lp_open: can't generate pipe cmd" );
+ spoolerror( out, NULL );
+ return( -1 );
+ }
if (( lp.lp_stream = popen(pipe_cmd, "w" )) == NULL ) {
LOG(log_error, logtype_papd, "lp_open popen %s: %s", printer->p_printer, strerror(errno) );
spoolerror( out, NULL );