From 7132f71cf010e4f13eb27c1a24d8878aa984b43f Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 29 Mar 2017 18:31:00 +0300 Subject: Remove extra memory copy in VirtFs::loadFile. Also add const into VirtFs::loadFile. --- src/gui/windows/updaterwindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/gui') diff --git a/src/gui/windows/updaterwindow.cpp b/src/gui/windows/updaterwindow.cpp index 082db75cd..6ef065eed 100644 --- a/src/gui/windows/updaterwindow.cpp +++ b/src/gui/windows/updaterwindow.cpp @@ -1069,7 +1069,7 @@ bool UpdaterWindow::validateFile(const std::string &filePath, unsigned long UpdaterWindow::getFileHash(const std::string &filePath) { int size = 0; - char *const buf = VirtFs::loadFile(filePath, size); + const char *const buf = VirtFs::loadFile(filePath, size); if (buf == nullptr) return 0; unsigned long res = Net::Download::adlerBuffer(buf, size); -- cgit v1.2.3-60-g2f50