Comment 1 for bug 1034504

Revision history for this message
sledgehammer999 (sledgehammer-999) wrote :

I found a solution and I suspect where the problem lies.

In qbtsession.cpp change line 1167

from:

const QString newFile = torrentBackup.absoluteFilePath(hash + ".torrent");

to:

const QString newFile = torrentBackup.absoluteFilePath(h.hash() + ".torrent");

Now the torrent is correctly removed from the session and the files get deleted to if I check the checkbox. I suspect that when you do "const QString hash = misc::toQString(t->info_hash());" in 1032 the value is actually uninitialized.

But now there is another problem too. If I pause a torrent and restart qbt the torrent is active instead of paused. Where should I look in the source? How do you save/load the state of the torrent?