diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2017-03-20 21:23:32 +0200 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2017-03-20 21:23:32 +0200 |
commit | 4dbaf72917b7c3e1592ccd2d4a787bb8b7a9fe54 (patch) | |
tree | 25e3ee3767b5ac816f68667b3dbe8184639141a6 /awk.h | |
parent | 65ed9b66cada11364e9b67ea1cd178b259cd0e36 (diff) | |
parent | efc7e96c876ccf3b83ab3249eca852a0292ff943 (diff) | |
download | egawk-4dbaf72917b7c3e1592ccd2d4a787bb8b7a9fe54.tar.gz egawk-4dbaf72917b7c3e1592ccd2d4a787bb8b7a9fe54.tar.bz2 egawk-4dbaf72917b7c3e1592ccd2d4a787bb8b7a9fe54.zip |
Merge branch 'master' into feature/api-mpfr
Diffstat (limited to 'awk.h')
-rw-r--r-- | awk.h | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -1586,6 +1586,10 @@ extern bool inrec(IOBUF *iop, int *errcode); extern int nextfile(IOBUF **curfile, bool skipping); extern bool is_non_fatal_std(FILE *fp); extern bool is_non_fatal_redirect(const char *str, size_t len); +extern void ignore_sigpipe(void); +extern void set_sigpipe_to_default(void); +extern bool non_fatal_flush_std_file(FILE *fp); + /* main.c */ extern int arg_assign(char *arg, bool initing); extern int is_std_var(const char *var); @@ -1975,3 +1979,11 @@ make_number_node(unsigned int tp) r->wstlen = 0; return r; } + +#ifdef SIGPIPE +#define ignore_sigpipe() signal(SIGPIPE, SIG_IGN) +#define set_sigpipe_to_default() signal(SIGPIPE, SIG_DFL) +#else +#define ignore_sigpipe() +#define set_sigpipe_to_default() +#endif |