From 9d79a51f1898eff6e96f799dd8f412a75c8a6839 Mon Sep 17 00:00:00 2001 From: Christophe Dumez Date: Tue, 12 Jan 2010 08:23:18 +0000 Subject: [PATCH] - Fix compilation error with libtorrent v0.14.3 --- src/misc.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/misc.h b/src/misc.h index 0d46fba21..8378a73a2 100644 --- a/src/misc.h +++ b/src/misc.h @@ -474,8 +474,7 @@ public: if(pos > -1) { QString found = regHex.cap(1); if(found.length() == 40) { - sha1_hash sha1; - sha1.assign(QString(QByteArray::fromHex(regHex.cap(1).toLocal8Bit())).toStdString()); + sha1_hash sha1(QString(QByteArray::fromHex(regHex.cap(1).toLocal8Bit())).toStdString()); qDebug("magnetUriToHash (Hex): hash: %s", misc::toString(sha1).c_str()); return misc::toQString(sha1); } @@ -486,8 +485,7 @@ public: if(pos > -1) { QString found = regBase32.cap(1); if(found.length() > 20 && (found.length()*5)%40 == 0) { - sha1_hash sha1; - sha1.assign(base32decode(regBase32.cap(1).toStdString())); + sha1_hash sha1(base32decode(regBase32.cap(1).toStdString())); hash = misc::toQString(sha1); } }