aboutsummaryrefslogtreecommitdiffstats
path: root/src/common.h
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2017-07-16 15:29:43 +0200
committerMattias Andrée <maandree@kth.se>2017-07-16 15:29:43 +0200
commitd05d162cb81664f292834fa5d48d623d2b6147a7 (patch)
tree9d4252fcdfa2210613188d5c965514cfab6a8ec2 /src/common.h
parentUse #include instead of #define (diff)
downloadblind-d05d162cb81664f292834fa5d48d623d2b6147a7.tar.gz
blind-d05d162cb81664f292834fa5d48d623d2b6147a7.tar.bz2
blind-d05d162cb81664f292834fa5d48d623d2b6147a7.tar.xz
Misc code improvements
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'src/common.h')
-rw-r--r--src/common.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/common.h b/src/common.h
index 6113edf..7d253c0 100644
--- a/src/common.h
+++ b/src/common.h
@@ -68,3 +68,11 @@
#if !defined(PIPE_BUF)
# define PIPE_BUF BUFSIZ
#endif
+
+#define SELECT_PROCESS_FUNCTION(stream)\
+ do {\
+ if ((stream)->encoding == DOUBLE)\
+ process = process_lf;\
+ else\
+ process = process_f;\
+ } while (0)