- if(!strcmp(opt_io, "-")) {
- iofd = STDOUT_FILENO;
- } else {
- if((iofd = open(opt_io, O_WRONLY | O_CREAT, 0666)) < 0) {
- fprintf(stderr, "Error opening %s:%s\n",
- opt_io, strerror(errno));
- }
+ iofd = (!strcmp(opt_io, "-")) ?
+ STDOUT_FILENO :
+ open(opt_io, O_WRONLY | O_CREAT, 0666);
+ if(iofd < 0) {
+ fprintf(stderr, "Error opening %s:%s\n",
+ opt_io, strerror(errno));