diff options
-rw-r--r-- | drivers/media/video/cx88/cx88-video.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/media/video/cx88/cx88-video.c b/drivers/media/video/cx88/cx88-video.c index 5ed1c5a52cdd..2092e439ef00 100644 --- a/drivers/media/video/cx88/cx88-video.c +++ b/drivers/media/video/cx88/cx88-video.c | |||
@@ -1277,15 +1277,12 @@ int cx88_enum_input (struct cx88_core *core,struct v4l2_input *i) | |||
1277 | [ CX88_VMUX_DVB ] = "DVB", | 1277 | [ CX88_VMUX_DVB ] = "DVB", |
1278 | [ CX88_VMUX_DEBUG ] = "for debug only", | 1278 | [ CX88_VMUX_DEBUG ] = "for debug only", |
1279 | }; | 1279 | }; |
1280 | unsigned int n; | 1280 | unsigned int n = i->index; |
1281 | 1281 | ||
1282 | n = i->index; | ||
1283 | if (n >= 4) | 1282 | if (n >= 4) |
1284 | return -EINVAL; | 1283 | return -EINVAL; |
1285 | if (0 == INPUT(n).type) | 1284 | if (0 == INPUT(n).type) |
1286 | return -EINVAL; | 1285 | return -EINVAL; |
1287 | memset(i,0,sizeof(*i)); | ||
1288 | i->index = n; | ||
1289 | i->type = V4L2_INPUT_TYPE_CAMERA; | 1286 | i->type = V4L2_INPUT_TYPE_CAMERA; |
1290 | strcpy(i->name,iname[INPUT(n).type]); | 1287 | strcpy(i->name,iname[INPUT(n).type]); |
1291 | if ((CX88_VMUX_TELEVISION == INPUT(n).type) || | 1288 | if ((CX88_VMUX_TELEVISION == INPUT(n).type) || |
@@ -1521,7 +1518,6 @@ static int radio_g_audio (struct file *file, void *priv, struct v4l2_audio *a) | |||
1521 | if (unlikely(a->index)) | 1518 | if (unlikely(a->index)) |
1522 | return -EINVAL; | 1519 | return -EINVAL; |
1523 | 1520 | ||
1524 | memset(a,0,sizeof(*a)); | ||
1525 | strcpy(a->name,"Radio"); | 1521 | strcpy(a->name,"Radio"); |
1526 | return 0; | 1522 | return 0; |
1527 | } | 1523 | } |