Changeset 3621 in MondoRescue for branches/3.3/mindi-busybox/printutils/lpd.c
- Timestamp:
- Dec 20, 2016, 4:07:32 PM (7 years ago)
- Location:
- branches/3.3
- Files:
-
- 1 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
branches/3.3/mindi-busybox/printutils/lpd.c
r3232 r3621 70 70 * mv -f ./"$DATAFILE" save/ 71 71 */ 72 //config:config LPD 73 //config: bool "lpd" 74 //config: default y 75 //config: help 76 //config: lpd is a print spooling daemon. 77 78 //applet:IF_LPD(APPLET(lpd, BB_DIR_USR_SBIN, BB_SUID_DROP)) 79 80 //kbuild:lib-$(CONFIG_LPD) += lpd.o 72 81 73 82 //usage:#define lpd_trivial_usage … … 201 210 goto unsupported_cmd; 202 211 if (spooling & (1 << (s[0]-1))) { 203 p rintf("Duplicated subcommand\n");212 puts("Duplicated subcommand"); 204 213 goto err_exit; 205 214 } 206 215 // get filename 207 *strchrnul(s, '\n') = '\0';216 chomp(s); 208 217 fname = strchr(s, ' '); 209 218 if (!fname) { 210 219 // bad_fname: 211 p rintf("No or bad filename\n");220 puts("No or bad filename"); 212 221 goto err_exit; 213 222 } … … 220 229 expected_len = bb_strtou(s + 1, NULL, 10); 221 230 if (errno || expected_len < 0) { 222 p rintf("Bad length\n");231 puts("Bad length"); 223 232 goto err_exit; 224 233 } … … 226 235 // SECURITY: 227 236 // ctrlfile can't be big (we want to read it back later!) 228 p rintf("File is too big\n");237 puts("File is too big"); 229 238 goto err_exit; 230 239 }
Note:
See TracChangeset
for help on using the changeset viewer.