aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/io.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/io.h b/include/io.h
index d9a1ae1..4f61cbf 100644
--- a/include/io.h
+++ b/include/io.h
@@ -8,15 +8,17 @@
#include <asm/unistd.h>
// `pfmt` uses fixed-size buffer on the stack for formating the message
-// (since we don't impl buffered I/O).
+// (for simplicity and since we don't impl buffered I/O).
//
// Size can be re-configured by defining `MAX_PRINTF_LEN` before including
// `io.h`.
//
-// NOTE: This allows to specify an arbitrarily large buffer on the stack, but
-// for the purpose of this study that's fine, we are cautious.
+// NOTE: This allows to specify a large buffer on the stack, but for
+// the purpose of this study that's fine, we are cautious.
#if !defined(MAX_PRINTF_LEN)
# define MAX_PRINTF_LEN 128
+#elif MAX_PRINTF_LEN > 512
+# error MAX_PRINTF_LEN is limited by 512!
#endif
#define FD_STDOUT 1