Explorar el Código

Avoid double free on I/O buffer when rtl_transmit() returns failure.

Convert printf() to DBG(); printf() is not allowed in drivers.
tags/v0.9.3
Michael Brown hace 17 años
padre
commit
e436b993a9
Se han modificado 1 ficheros con 1 adiciones y 2 borrados
  1. 1
    2
      src/drivers/net/rtl8139.c

+ 1
- 2
src/drivers/net/rtl8139.c Ver fichero

@@ -380,8 +380,7 @@ static int rtl_transmit ( struct net_device *netdev, struct io_buffer *iobuf ) {
380 380
 
381 381
 	/* Check for space in TX ring */
382 382
 	if ( rtl->tx.iobuf[rtl->tx.next] != NULL ) {
383
-		printf ( "TX overflow\n" );
384
-		free_iob ( iobuf );
383
+		DBG ( "TX overflow\n" );
385 384
 		return -ENOBUFS;
386 385
 	}
387 386
 

Loading…
Cancelar
Guardar