From 3ea80c7c7cc5bdb8e247776a87820a7da078b39a Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Wed, 25 Apr 2018 16:46:20 +0200 Subject: [PATCH] Compare ints instead of floats for progress check --- plugins/Toolbox/src/Toolbox.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/Toolbox/src/Toolbox.py b/plugins/Toolbox/src/Toolbox.py index fdc089ae2d..d759619b3c 100644 --- a/plugins/Toolbox/src/Toolbox.py +++ b/plugins/Toolbox/src/Toolbox.py @@ -485,7 +485,7 @@ class Toolbox(QObject, Extension): if bytes_total > 0: new_progress = bytes_sent / bytes_total * 100 self.setDownloadProgress(new_progress) - if new_progress == 100.0: + if bytes_sent == bytes_total: self.setIsDownloading(False) self._download_reply.downloadProgress.disconnect(self._onDownloadProgress) # must not delete the temporary file on Windows