Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 282312
b: refs/heads/master
c: 4c33a88
h: refs/heads/master
v: v3
  • Loading branch information
Thomas Meyer authored and Jiri Kosina committed Nov 19, 2011
1 parent f9db2de commit a500cbf
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1f59169e191c62e66dda86ac2bc953c915c8dddf
refs/heads/master: 4c33a885a5c8a9ad573249fa4ee4fb39af866599
4 changes: 1 addition & 3 deletions trunk/drivers/hid/hid-roccat-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,10 @@ int roccat_common_send(struct usb_device *usb_dev, uint report_id,
char *buf;
int len;

buf = kmalloc(size, GFP_KERNEL);
buf = kmemdup(data, size, GFP_KERNEL);
if (buf == NULL)
return -ENOMEM;

memcpy(buf, data, size);

len = usb_control_msg(usb_dev, usb_sndctrlpipe(usb_dev, 0),
HID_REQ_SET_REPORT,
USB_TYPE_CLASS | USB_RECIP_INTERFACE | USB_DIR_OUT,
Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/hid/hid-roccat-kone.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,10 @@ static int kone_send(struct usb_device *usb_dev, uint usb_command,
char *buf;
int len;

buf = kmalloc(size, GFP_KERNEL);
buf = kmemdup(data, size, GFP_KERNEL);
if (buf == NULL)
return -ENOMEM;

memcpy(buf, data, size);

len = usb_control_msg(usb_dev, usb_sndctrlpipe(usb_dev, 0),
HID_REQ_SET_REPORT,
USB_TYPE_CLASS | USB_RECIP_INTERFACE | USB_DIR_OUT,
Expand Down

0 comments on commit a500cbf

Please sign in to comment.