From f8f9b79f7c0c01903fee2304b252f34ecfb31fdd Mon Sep 17 00:00:00 2001 From: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com> Date: Wed, 1 Dec 2021 11:45:59 -0800 Subject: [PATCH] Removes ToolFileUtils_generic.cpp from AzToolsFramework Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com> --- .../ToolsFileUtils/ToolsFileUtils_generic.cpp | 47 ------------------- 1 file changed, 47 deletions(-) delete mode 100644 Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp deleted file mode 100644 index 8357a265ba..0000000000 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/ToolsFileUtils/ToolsFileUtils_generic.cpp +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include "ToolsFileUtils.h" -#include -#include - -#include - -namespace AzToolsFramework -{ - namespace ToolsFileUtils - { - bool SetModificationTime(const char* const filename, AZ::u64 modificationTime) - { - struct stat statResult; - if (stat(filename, &statResult) != 0) - { - return false; - } - - struct utimbuf puttime; - puttime.modtime = modificationTime; - puttime.actime = static_cast(statResult.st_ctime); - - if (utime(filename, &puttime) == 0) - { - return true; - } - - return false; - } - - bool GetFreeDiskSpace(const QString& path, qint64& outFreeDiskSpace) - { - QStorageInfo storageInfo(path); - outFreeDiskSpace = storageInfo.bytesFree(); - - return outFreeDiskSpace >= 0; - } - } -}