Lines Matching refs:command
27 static int do_command(int outfd, int infd, const char *command);
194 const char *command) /* I - Command line to send */ in do_command() argument
200 printf("COMMAND: %02X %s", command[0], command + 1); in do_command()
202 len = strlen(command); in do_command()
204 if ((size_t)write(outfd, command, len) < len) in do_command()
230 char command[1024], /* Command buffer */ in print_job() local
260 snprintf(command, sizeof(command), "\002%s\n", dest); in print_job()
261 if ((status = do_command(outfd, infd, command)) != 0) in print_job()
293 snprintf(command, sizeof(command), "\002%d cfA%03dlocalhost\n", in print_job()
296 if ((status = do_command(outfd, infd, command)) != 0) in print_job()
313 if (read(infd, command, 1) < 1) in print_job()
321 status = command[0]; in print_job()
330 snprintf(command, sizeof(command), "\003%d dfA%03dlocalhost\n", in print_job()
333 if ((status = do_command(outfd, infd, command)) != 0) in print_job()
355 if (read(infd, command, 1) < 1) in print_job()
363 status = command[0]; in print_job()
381 char command[1024]; /* Command buffer */ in print_waiting() local
388 snprintf(command, sizeof(command), "\001%s\n", dest); in print_waiting()
390 return (do_command(outfd, infd, command)); in print_waiting()
405 char command[1024]; /* Command buffer */ in remove_job() local
411 snprintf(command, sizeof(command), "\005%s", dest); in remove_job()
415 strlcat(command, " ", sizeof(command)); in remove_job()
416 strlcat(command, args[i], sizeof(command)); in remove_job()
419 strlcat(command, "\n", sizeof(command)); in remove_job()
421 return (do_command(outfd, infd, command)); in remove_job()
435 char command[1024], /* Command buffer */ in status_long() local
445 snprintf(command, sizeof(command), "\004%s %s\n", dest, args[0]); in status_long()
447 snprintf(command, sizeof(command), "\004%s\n", dest); in status_long()
449 bytes = (ssize_t)strlen(command); in status_long()
451 if (write(outfd, command, (size_t)bytes) < bytes) in status_long()
478 char command[1024], /* Command buffer */ in status_short() local
488 snprintf(command, sizeof(command), "\003%s %s\n", dest, args[0]); in status_short()
490 snprintf(command, sizeof(command), "\003%s\n", dest); in status_short()
492 bytes = (ssize_t)strlen(command); in status_short()
494 if (write(outfd, command, (size_t)bytes) < bytes) in status_short()