Commit 8eb3bb282ea473831cd01333621bba2885dcf65b

Daniel Mendler 2019-03-22T15:02:29

do not include stdio.h if LTM_NO_FILE is defined stdio.h might not be available on constraint environments

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
diff --git a/tommath.h b/tommath.h
index e0eb259..71ecaf5 100644
--- a/tommath.h
+++ b/tommath.h
@@ -12,11 +12,14 @@
 #ifndef BN_H_
 #define BN_H_
 
-#include <stdio.h>
 #include <stdlib.h>
 #include <stdint.h>
 #include <limits.h>
 
+#ifndef LTM_NO_FILE
+#  include <stdio.h>
+#endif
+
 #include "tommath_class.h"
 
 #ifdef __cplusplus