Changeset 28510 in vbox for trunk/src/VBox/Devices/Network
- Timestamp:
- Apr 20, 2010 10:25:22 AM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 60309
- Location:
- trunk/src/VBox/Devices/Network/slirp
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Network/slirp/sbuf.c
r28449 r28510 43 43 { 44 44 /* 45 * vvl: This assert to catch double frees. tcp_close filter out46 * listening sockets which pass NULLs here.45 * Catch double frees. Actually tcp_close() already filters out listening sockets 46 * passing NULL. 47 47 */ 48 48 Assert((sb->sb_data)); 49 RTMemFree(sb->sb_data); 50 /** @todo bird: I'm seeing double frees here sometimes. This NULL'ing is just a 51 workaround for that, it doesn't actually fix anything. */ 52 sb->sb_data = NULL; 49 50 /* 51 * Don't call RTMemFree() for an already freed buffer, the EFence could complain 52 */ 53 if (sb->sb_data) 54 { 55 RTMemFree(sb->sb_data); 56 sb->sb_data = NULL; 57 } 53 58 } 54 59 -
trunk/src/VBox/Devices/Network/slirp/tcp_subr.c
r28482 r28510 312 312 tcp_last_so = &tcb; 313 313 closesocket(so->s); 314 /* (vvl) opening listening socket we do not reserve sbufs for it */ 315 if ((so->so_state & SS_FACCEPTCONN) == 0) 314 /* Avoid double free if the socket is listening and therefore doesn't have 315 * any sbufs reserved. */ 316 if (!(so->so_state & SS_FACCEPTCONN)) 316 317 { 317 318 sbfree(&so->so_rcv);
Note:
See TracChangeset
for help on using the changeset viewer.