Explorar el Código

Use the piece destructor.

master
Richard Nyberg hace 20 años
padre
commit
d8720e889c
Se han modificado 1 ficheros con 2 adiciones y 6 borrados
  1. +2
    -6
      btpd/torrent.c

+ 2
- 6
btpd/torrent.c Ver fichero

@@ -171,12 +171,8 @@ torrent_unload(struct torrent *tp)
peer = next;
}

piece = BTPDQ_FIRST(&tp->getlst);
while (piece != NULL) {
struct piece *next = BTPDQ_NEXT(piece, entry);
free(piece);
piece = next;
}
while ((piece = BTPDQ_FIRST(&tp->getlst)) != NULL)
piece_free(piece);

free(tp->piece_count);
free(tp->busy_field);


Cargando…
Cancelar
Guardar