version 1.16, 2020/05/24 17:31:54 |
version 1.17, 2020/05/24 18:27:07 |
|
|
/* routines for printing error messages */ |
/* routines for printing error messages */ |
|
|
#include "defs.h" |
#include "defs.h" |
|
#include <errno.h> |
|
|
|
|
void |
void |
|
|
void |
void |
open_error(char *filename) |
open_error(char *filename) |
{ |
{ |
fprintf(stderr, "%s: cannot open source file %s\n", |
fprintf(stderr, "%s: cannot open source file %s: %s\n", |
input_file_name, filename); |
input_file_name, filename, strerror(errno)); |
exit(2); |
exit(2); |
} |
} |
|
|
void |
void |
tempfile_error(void) |
tempfile_error(void) |
{ |
{ |
fprintf(stderr, "%s: cannot create temporary file\n", |
fprintf(stderr, "%s: cannot create temporary file: %s\n", |
input_file_name); |
input_file_name, strerror(errno)); |
exit(2); |
exit(2); |
} |
} |
|
|
void |
void |
open_write_error(char *filename) |
open_write_error(char *filename) |
{ |
{ |
fprintf(stderr, "%s: cannot open target file %s for writing\n", |
fprintf(stderr, "%s: cannot open target file %s for writing: %s\n", |
input_file_name, filename); |
input_file_name, filename, strerror(errno)); |
exit(2); |
exit(2); |
} |
} |
|
|