downloads: Rewind file objects correctly on redirects.
This commit is contained in:
parent
9333e92891
commit
f7fbf98667
@ -402,6 +402,8 @@ class DownloadItem(QObject):
|
|||||||
reply = self._reply
|
reply = self._reply
|
||||||
reply.finished.disconnect(self.on_reply_finished)
|
reply.finished.disconnect(self.on_reply_finished)
|
||||||
self._reply = None
|
self._reply = None
|
||||||
|
if self.fileobj is not None:
|
||||||
|
self.fileobj.seek(0)
|
||||||
self.redirected.emit(request, reply) # this will change self._reply!
|
self.redirected.emit(request, reply) # this will change self._reply!
|
||||||
reply.deleteLater() # the old one
|
reply.deleteLater() # the old one
|
||||||
return True
|
return True
|
||||||
|
Loading…
Reference in New Issue
Block a user