mirror of https://github.com/ipxe/ipxe.git
Avoid double free on I/O buffer when rtl_transmit() returns failure.
Convert printf() to DBG(); printf() is not allowed in drivers.pull/1/head
parent
0958726ebb
commit
e436b993a9
|
@ -380,8 +380,7 @@ static int rtl_transmit ( struct net_device *netdev, struct io_buffer *iobuf ) {
|
||||||
|
|
||||||
/* Check for space in TX ring */
|
/* Check for space in TX ring */
|
||||||
if ( rtl->tx.iobuf[rtl->tx.next] != NULL ) {
|
if ( rtl->tx.iobuf[rtl->tx.next] != NULL ) {
|
||||||
printf ( "TX overflow\n" );
|
DBG ( "TX overflow\n" );
|
||||||
free_iob ( iobuf );
|
|
||||||
return -ENOBUFS;
|
return -ENOBUFS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue