Skip to content

Commit

Permalink
ps3_gelic: fix memcpy parameter
Browse files Browse the repository at this point in the history
The size allocated for target->hwinfo and the number of bytes copied in it
should be consistent.

Signed-off-by: Christophe JAILLET <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
tititiou36 authored and davem330 committed Apr 28, 2016
1 parent 14437e3 commit eb63efb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/ethernet/toshiba/ps3_gelic_wireless.c
Original file line number Diff line number Diff line change
Expand Up @@ -1622,7 +1622,7 @@ static void gelic_wl_scan_complete_event(struct gelic_wl_info *wl)
continue;

/* copy hw scan info */
memcpy(target->hwinfo, scan_info, scan_info->size);
memcpy(target->hwinfo, scan_info, be16_to_cpu(scan_info->size));
target->essid_len = strnlen(scan_info->essid,
sizeof(scan_info->essid));
target->rate_len = 0;
Expand Down

0 comments on commit eb63efb

Please sign in to comment.