Skip to contentSkip to conversation

Add missing stdlib.h and ctype.h includes

PATCH In review Andreas Bombe 2 participants 2 messages Feb 18, 2013 – Mar 25, 2013 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Add missing stdlib.h and ctype.h includes

src/mediactl.c needs ctype.h for its use of isspace().

src/v4l2subdev.c needs stdlib.h for strtoul() and ctype.h for isspace() and isupper().

---
 src/mediactl.c   |    1 +
 src/v4l2subdev.c |    2 ++
 2 files changed, 3 insertions(+)
src/mediactl.c +1 -0
index 46562de..c2f985a 100644
@@ -29,6 +29,7 @@
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <ctype.h>
 #include <string.h>
 #include <fcntl.h>
 #include <errno.h>
src/v4l2subdev.c +2 -0
index d0c37f3..87d7eb7 100644
@@ -26,6 +26,8 @@
 #include <errno.h>
 #include <fcntl.h>
 #include <stdbool.h>
+#include <stdlib.h>
+#include <ctype.h>
 #include <stdio.h>
 #include <string.h>
 #include <unistd.h>
Signature · 1 line
1.7.10.4
Acked-by on v1 1/1
#1 lore raw

Hi Andreas,

Thanks for the patch, and sorry for the late reply.

Quoted 6 lines · On Monday 18 February 2013 01:12:44 Andreas Bombe wrote:

src/mediactl.c needs ctype.h for its use of isspace().

src/v4l2subdev.c needs stdlib.h for strtoul() and ctype.h for isspace() and isupper().

and pushed to the repository.

Quoted 30 lines
---
 src/mediactl.c   |    1 +
 src/v4l2subdev.c |    2 ++
 2 files changed, 3 insertions(+)
src/mediactl.c +1 -0
index 46562de..c2f985a 100644
@@ -29,6 +29,7 @@
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <ctype.h>
 #include <string.h>
 #include <fcntl.h>
 #include <errno.h>
src/v4l2subdev.c +2 -0
index d0c37f3..87d7eb7 100644
@@ -26,6 +26,8 @@
 #include <errno.h>
 #include <fcntl.h>
 #include <stdbool.h>
+#include <stdlib.h>
+#include <ctype.h>
 #include <stdio.h>
 #include <string.h>
 #include <unistd.h>
Signature · 3 lines
Regards,

Laurent Pinchart