From: Julia Lawall Date: Sun, 30 Nov 2014 18:14:15 +0000 (+0100) Subject: usbip: remove unneeded structure X-Git-Tag: v4.14-rc1~6297^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b19e5f04cd628c012c26a025cf93da5233df134d;p=platform%2Fkernel%2Flinux-rpi.git usbip: remove unneeded structure Delete a local structure that is only used to be initialized by memset. A semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ identifier x,i; @@ { ... when any -struct i x; <+... when != x - memset(&x,...); ...+> } // Signed-off-by: Julia Lawall Acked-by: Valentina Manea Signed-off-by: Greg Kroah-Hartman --- diff --git a/tools/usb/usbip/src/usbipd.c b/tools/usb/usbip/src/usbipd.c index 2f87f2d..2a7cd2b 100644 --- a/tools/usb/usbip/src/usbipd.c +++ b/tools/usb/usbip/src/usbipd.c @@ -91,7 +91,6 @@ static void usbipd_help(void) static int recv_request_import(int sockfd) { struct op_import_request req; - struct op_common reply; struct usbip_exported_device *edev; struct usbip_usb_device pdu_udev; struct list_head *i; @@ -100,7 +99,6 @@ static int recv_request_import(int sockfd) int rc; memset(&req, 0, sizeof(req)); - memset(&reply, 0, sizeof(reply)); rc = usbip_net_recv(sockfd, &req, sizeof(req)); if (rc < 0) {