From 9dd7f6c6cf28c64b6270853e6fe9f1673bbbb9e3 Mon Sep 17 00:00:00 2001 From: Marcos Pinto Date: Tue, 7 Aug 2007 06:58:34 +0000 Subject: [PATCH] piece fix -micah --- src/deluge_core.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/deluge_core.cpp b/src/deluge_core.cpp index 4282e1e28..9cbfa1daf 100644 --- a/src/deluge_core.cpp +++ b/src/deluge_core.cpp @@ -763,7 +763,7 @@ static PyObject *torrent_has_piece(PyObject *self, PyObject *args) return NULL; torrent_status s = M_torrents->at(index).handle.status(); - if ((*s.pieces).size() == 0) + if (s.pieces == 0) return Py_BuildValue("b", false); has_piece = internal_has_piece(*s.pieces, piece_index); return Py_BuildValue("b", has_piece);