diff options
author | Andreas Fritiofson <andreas.fritiofson@gmail.com> | 2013-09-28 21:43:37 +0200 |
---|---|---|
committer | Spencer Oliver <spen@spen-soft.co.uk> | 2013-10-31 20:43:27 +0000 |
commit | ba2fbe22470915359e1905aaad4c613eacbdf6dc (patch) | |
tree | 701c642d7bd3badb2b97b971cce811c4140e778b /src/jtag/drivers/opendous.c | |
parent | 704082443d03cdeba9c89a8f70d1f1017330d903 (diff) |
Remove unnecessary casts
Change-Id: Ia97283707282ccccdc707c969f59337313b4e291
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/1767
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Diffstat (limited to 'src/jtag/drivers/opendous.c')
-rw-r--r-- | src/jtag/drivers/opendous.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/jtag/drivers/opendous.c b/src/jtag/drivers/opendous.c index f58dc924..74be680a 100644 --- a/src/jtag/drivers/opendous.c +++ b/src/jtag/drivers/opendous.c @@ -350,8 +350,8 @@ static int opendous_init(void) usb_in_buffer = malloc(opendous_probe->BUFFERSIZE); usb_out_buffer = malloc(opendous_probe->BUFFERSIZE); - pending_scan_results_buffer = (struct pending_scan_result *) - malloc(MAX_PENDING_SCAN_RESULTS * sizeof(struct pending_scan_result)); + pending_scan_results_buffer = malloc( + MAX_PENDING_SCAN_RESULTS * sizeof(*pending_scan_results_buffer)); opendous_jtag_handle = opendous_usb_open(); @@ -718,7 +718,7 @@ struct opendous_jtag *opendous_usb_open(void) jtag_libusb_set_configuration(devh, 0); jtag_libusb_claim_interface(devh, 0); - result = (struct opendous_jtag *) malloc(sizeof(struct opendous_jtag)); + result = malloc(sizeof(*result)); result->usb_handle = devh; return result; } |