about summary refs log tree commit diff stats
path: root/src/common.h
diff options
context:
space:
mode:
authorPeter Vilim <peterlvilim@users.noreply.github.com>2015-01-07 21:37:35 -0600
committerPeter Vilim <peterlvilim@users.noreply.github.com>2015-01-07 21:37:35 -0600
commit0cb548683c906eb7e48ddfccde4b95f671dea5fc (patch)
tree0dce7c2d92fd90111e4cf0beb0b5d232094b2772 /src/common.h
parentb298994ce755d4ddc0c7de882c989e58806c212d (diff)
downloadprofani-tty-0cb548683c906eb7e48ddfccde4b95f671dea5fc.tar.gz
fgets: buffer size
Diffstat (limited to 'src/common.h')
-rw-r--r--src/common.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/common.h b/src/common.h
index 6497e666..55451dea 100644
--- a/src/common.h
+++ b/src/common.h
@@ -59,6 +59,11 @@
 
 #define ARRAY_SIZE(x) (sizeof(x)/sizeof(x[0]))
 
+// assume malloc stores at most 8 bytes for size of allocated memory
+// and page size is at least 4KB
+#define READ_BUF_SIZE 4088
+
+
 #define FREE_SET_NULL(resource) \
 do { \
     free(resource); \