diff options
| author | Takashi Iwai <tiwai@suse.de> | 2009-05-12 11:57:09 +0200 |
|---|---|---|
| committer | Takashi Iwai <tiwai@suse.de> | 2009-05-12 11:57:09 +0200 |
| commit | ddc4097b77bbb227851a44287acb2fb8a9896cc1 (patch) | |
| tree | 319d098879bed7c45543d983de8becd509701b22 /drivers/hid/hidraw.c | |
| parent | bec4c99e8637b5b8bd4b0513eacb51da25885e3b (diff) | |
| parent | ae31c1fbdbb18d917b0a1139497c2dbd35886989 (diff) | |
Merge branch 'topic/drvdata-fix' into topic/asoc
Diffstat (limited to 'drivers/hid/hidraw.c')
| -rw-r--r-- | drivers/hid/hidraw.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c index e263d473117..00ccf4b1985 100644 --- a/drivers/hid/hidraw.c +++ b/drivers/hid/hidraw.c @@ -285,8 +285,10 @@ static long hidraw_ioctl(struct file *file, unsigned int cmd, if (_IOC_NR(cmd) == _IOC_NR(HIDIOCGRAWNAME(0))) { int len; - if (!hid->name) - return 0; + if (!hid->name) { + ret = 0; + break; + } len = strlen(hid->name) + 1; if (len > _IOC_SIZE(cmd)) len = _IOC_SIZE(cmd); @@ -297,8 +299,10 @@ static long hidraw_ioctl(struct file *file, unsigned int cmd, if (_IOC_NR(cmd) == _IOC_NR(HIDIOCGRAWPHYS(0))) { int len; - if (!hid->phys) - return 0; + if (!hid->phys) { + ret = 0; + break; + } len = strlen(hid->phys) + 1; if (len > _IOC_SIZE(cmd)) len = _IOC_SIZE(cmd); |
