diff options
author | Michael Krufky <mkrufky@linuxtv.org> | 2008-09-25 08:37:12 -0400 |
---|---|---|
committer | Michael Krufky <mkrufky@linuxtv.org> | 2008-09-25 08:37:12 -0400 |
commit | 7e39de54b4ed06bb2ababbe72b16f195d796d8f0 (patch) | |
tree | 5a74da414f5b1aaa78712988a989a00a94736648 /v4l2-apps/lib/libv4l/libv4l1/log.c | |
parent | 968c43076f37c9f65df65fe50a1c643a82b1192b (diff) | |
parent | 9385e4874ef72f62d77800fe2eb47429d0854125 (diff) | |
download | mediapointer-dvb-s2-7e39de54b4ed06bb2ababbe72b16f195d796d8f0.tar.gz mediapointer-dvb-s2-7e39de54b4ed06bb2ababbe72b16f195d796d8f0.tar.bz2 |
merge: ~pb/v4l-dvb
From: Michael Krufky <mkrufky@linuxtv.org>
Priority: normal
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Diffstat (limited to 'v4l2-apps/lib/libv4l/libv4l1/log.c')
-rw-r--r-- | v4l2-apps/lib/libv4l/libv4l1/log.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/v4l2-apps/lib/libv4l/libv4l1/log.c b/v4l2-apps/lib/libv4l/libv4l1/log.c index 74ce0f20b..9ff0cea46 100644 --- a/v4l2-apps/lib/libv4l/libv4l1/log.c +++ b/v4l2-apps/lib/libv4l/libv4l1/log.c @@ -66,6 +66,7 @@ static const char *v4l1_ioctls[] = { void v4l1_log_ioctl(unsigned long int request, void *arg, int result) { const char *ioctl_str = "unknown"; + char buf[40]; if (!v4l1_log_file) return; @@ -77,6 +78,11 @@ void v4l1_log_ioctl(unsigned long int request, void *arg, int result) if (_IOC_TYPE(request) == 'v' && _IOC_NR(request) < ARRAY_SIZE(v4l1_ioctls)) ioctl_str = v4l1_ioctls[_IOC_NR(request)]; + else { + snprintf(buf, sizeof(buf), "unknown request: %c %d\n", + (int)_IOC_TYPE(request), (int)_IOC_NR(request)); + ioctl_str = buf; + } fprintf(v4l1_log_file, "request == %s\n", ioctl_str); |