Changeset 54780 in vbox for trunk/src/VBox
- Timestamp:
- Mar 16, 2015 12:34:11 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/RDP/client/vrdp/rdpusb.c
r50234 r54780 98 98 #pragma pack () 99 99 100 /** 101 * @returns VBox status code. 102 */ 100 103 static inline int op_usbproxy_back_open(PUSBPROXYDEV p, const char *pszAddress) 101 104 { … … 108 111 } 109 112 113 /** 114 * @returns VBox status code. 115 */ 110 116 static inline int op_usbproxy_back_reset(PUSBPROXYDEV pDev) 111 117 { … … 113 119 } 114 120 121 /** 122 * @returns VBox status code. 123 */ 115 124 static inline int op_usbproxy_back_set_config(PUSBPROXYDEV pDev, int cfg) 116 125 { … … 118 127 } 119 128 129 /** 130 * @returns VBox status code. 131 */ 120 132 static inline int op_usbproxy_back_claim_interface(PUSBPROXYDEV pDev, int ifnum) 121 133 { … … 123 135 } 124 136 137 /** 138 * @returns VBox status code. 139 */ 125 140 static inline int op_usbproxy_back_release_interface(PUSBPROXYDEV pDev, int ifnum) 126 141 { … … 128 143 } 129 144 145 /** 146 * @returns VBox status code. 147 */ 130 148 static inline int op_usbproxy_back_interface_setting(PUSBPROXYDEV pDev, int ifnum, int setting) 131 149 { … … 133 151 } 134 152 153 /** 154 * @returns VBox status code. 155 */ 135 156 static inline int op_usbproxy_back_queue_urb(PUSBPROXYDEV pDev, PVUSBURB pUrb) 136 157 { … … 143 164 } 144 165 145 static inline bool op_usbproxy_back_clear_halted_ep(PUSBPROXYDEV pDev, unsigned EndPoint) 166 /** 167 * @returns VBox status code. 168 */ 169 static inline int op_usbproxy_back_clear_halted_ep(PUSBPROXYDEV pDev, unsigned EndPoint) 146 170 { 147 171 return g_USBProxyDeviceHost.pfnClearHaltedEndpoint (pDev, EndPoint); 148 172 } 149 173 174 /** 175 * @returns VBox status code. 176 */ 150 177 static inline int op_usbproxy_back_cancel_urb(PUSBPROXYDEV pDev, PVUSBURB pUrb) 151 178 { … … 471 498 } 472 499 500 memset (proxy, 0, sizeof (USBPROXYDEV)); 501 473 502 proxy->pvInstanceDataR3 = xmalloc(g_USBProxyDeviceHost.cbBackend); 474 503 if (!proxy->pvInstanceDataR3) … … 477 506 return; 478 507 } 479 480 memset (proxy, 0, sizeof (USBPROXYDEV));481 508 482 509 proxy->Dev.pszName = "Remote device"; … … 551 578 552 579 rc = op_usbproxy_back_reset(proxy); 553 554 580 if (rc != VINF_SUCCESS) 555 581 { … … 574 600 575 601 rc = op_usbproxy_back_set_config(proxy, cfg); 576 577 if (!rc) 602 if (RT_FAILURE(rc)) 578 603 { 579 604 rdpusb_send_reply (code, vrdp_usb_status (rc, &proxy->Dev), devid); … … 595 620 596 621 in_uint8(s, ifnum); 622 in_uint8(s, ifnum); 597 623 598 624 rc = op_usbproxy_back_claim_interface(proxy, ifnum); 599 600 if (!rc) 625 if (RT_FAILURE(rc)) 601 626 { 602 627 rdpusb_send_reply (code, vrdp_usb_status (rc, &proxy->Dev), devid); … … 620 645 621 646 rc = op_usbproxy_back_release_interface(proxy, ifnum); 622 623 if (!rc) 647 if (RT_FAILURE(rc)) 624 648 { 625 649 rdpusb_send_reply (code, vrdp_usb_status (rc, &proxy->Dev), devid); … … 645 669 646 670 rc = op_usbproxy_back_interface_setting(proxy, ifnum, setting); 647 648 if (!rc) 671 if (RT_FAILURE(rc)) 649 672 { 650 673 rdpusb_send_reply (code, vrdp_usb_status (rc, &proxy->Dev), devid); … … 703 726 /* No reply required. */ 704 727 705 if ( rc)728 if (RT_SUCCESS(rc)) 706 729 { 707 730 if (proxy->pUrbs) … … 740 763 741 764 rc = op_usbproxy_back_clear_halted_ep(proxy, ep); 742 743 if (!rc) 765 if (RT_FAILURE(rc)) 744 766 { 745 767 rdpusb_send_reply (code, vrdp_usb_status (rc, &proxy->Dev), devid);
Note:
See TracChangeset
for help on using the changeset viewer.