From 253922fc720f48e98e6bc9030b5c712044ab83fc Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Wed, 23 Jul 2008 13:10:10 +0200 Subject: v4l2-apps: fixes for compile warnings/errors From: Hans Verkuil - clean up capture_example.c (bad codingstyle and compile warnings) - fix some headers without trailing newline - fix compile warnings in v4l2-ctl.cpp and v4l2-dbg.cpp - fix qv4l2 __stack_chk_fail_local compile error that occurs on some distros (ubuntu) - fix some Makefile clean up rules Signed-off-by: Hans Verkuil --- v4l2-apps/util/v4l2-ctl.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'v4l2-apps/util/v4l2-ctl.cpp') diff --git a/v4l2-apps/util/v4l2-ctl.cpp b/v4l2-apps/util/v4l2-ctl.cpp index 57d98fc13..3e56e63a1 100644 --- a/v4l2-apps/util/v4l2-ctl.cpp +++ b/v4l2-apps/util/v4l2-ctl.cpp @@ -1019,9 +1019,9 @@ static int doioctl(int fd, int request, void *parm, const char *name) return retVal; } -static int parse_subopt(char **subs, char * const *subopts, char **value) +static int parse_subopt(char **subs, const char * const *subopts, char **value) { - int opt = getsubopt(subs, subopts, value); + int opt = getsubopt(subs, (char * const *)subopts, value); if (opt == -1) { fprintf(stderr, "Invalid suboptions specified\n"); @@ -1094,7 +1094,7 @@ static void parse_crop(char *optarg, unsigned int &set_crop, v4l2_rect &vcrop) char *subs = optarg; while (*subs != '\0') { - static char *const subopts[] = { + static const char *const subopts[] = { "left", "top", "width", @@ -1230,7 +1230,7 @@ int main(int argc, char **argv) case OptSetVideoFormat: subs = optarg; while (*subs != '\0') { - static char *const subopts[] = { + static const char *const subopts[] = { "width", "height", NULL @@ -1251,7 +1251,7 @@ int main(int argc, char **argv) case OptSetVideoOutFormat: subs = optarg; while (*subs != '\0') { - static char *const subopts[] = { + static const char *const subopts[] = { "width", "height", NULL @@ -1272,7 +1272,7 @@ int main(int argc, char **argv) case OptSetOutputOverlayFormat: subs = optarg; while (*subs != '\0') { - static char *const subopts[] = { + static const char *const subopts[] = { "chromakey", "global_alpha", NULL @@ -1293,7 +1293,7 @@ int main(int argc, char **argv) case OptSetFBuf: subs = optarg; while (*subs != '\0') { - static char *const subopts[] = { + static const char *const subopts[] = { "chromakey", "global_alpha", "local_alpha", @@ -1428,7 +1428,7 @@ int main(int argc, char **argv) fmt->fmt.sliced.service_set = 0; subs = optarg; while (*subs != '\0') { - static char *const subopts[] = { + static const char *const subopts[] = { "off", "teletext", "cc", -- cgit v1.2.3