diff mbox

include stdint.h explicitly for UINT16_MAX)

Message ID 20170520212846.3534-1-raj.khem@gmail.com
State New
Headers show

Commit Message

Khem Raj May 20, 2017, 9:28 p.m. UTC
Fixes
| tc_core.c:190:29: error: 'UINT16_MAX' undeclared (first use in this function); did you mean '__INT16_MAX__'?
|    if ((sz >> s->size_log) > UINT16_MAX) {
|                              ^~~~~~~~~~

Signed-off-by: Khem Raj <raj.khem@gmail.com>

---
 tc/tc_core.c | 1 +
 1 file changed, 1 insertion(+)

-- 
2.13.0

Comments

Stephen Hemminger May 22, 2017, 6:44 p.m. UTC | #1
On Sat, 20 May 2017 14:28:46 -0700
Khem Raj <raj.khem@gmail.com> wrote:

> Fixes

> | tc_core.c:190:29: error: 'UINT16_MAX' undeclared (first use in this function); did you mean '__INT16_MAX__'?

> |    if ((sz >> s->size_log) > UINT16_MAX) {

> |                              ^~~~~~~~~~

> 

> Signed-off-by: Khem Raj <raj.khem@gmail.com>


Applied.
diff mbox

Patch

diff --git a/tc/tc_core.c b/tc/tc_core.c
index 7bbe0d7..821b741 100644
--- a/tc/tc_core.c
+++ b/tc/tc_core.c
@@ -12,6 +12,7 @@ 
 
 #include <stdio.h>
 #include <stdlib.h>
+#include <stdint.h>
 #include <unistd.h>
 #include <syslog.h>
 #include <fcntl.h>