From 1cdc88682bac2c54f7880bc62ca18939a56c849a Mon Sep 17 00:00:00 2001 From: TheWahlolly Date: Tue, 1 Jul 2025 12:38:23 +0300 Subject: [PATCH] v1.12.2 - Fixed a bug in the filesystem library where moving a file to a different drive would error out. --- argentum.cfg | 2 +- halyde/core/boot.lua | 2 +- halyde/lib/filesystem.lua | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/argentum.cfg b/argentum.cfg index b7e8a0b..9944e1a 100644 --- a/argentum.cfg +++ b/argentum.cfg @@ -1,7 +1,7 @@ local agcfg = { ["halyde"] = { ["maindir"] = "", - ["version"] = "1.12.1", + ["version"] = "1.12.2", ["description"] = "A universal, customizable and feature-packed operating system for OpenComputers.", ["directories"] = { "halyde/apps", diff --git a/halyde/core/boot.lua b/halyde/core/boot.lua index 292a996..11c5b9a 100644 --- a/halyde/core/boot.lua +++ b/halyde/core/boot.lua @@ -1,7 +1,7 @@ local loadfile = ... local filesystem = loadfile("/halyde/lib/filesystem.lua")(loadfile) -_G._OSVERSION = "Halyde 1.12.1" +_G._OSVERSION = "Halyde 1.12.2" _G._OSLOGO = "" local handle, tmpdata = filesystem.open("/halyde/config/oslogo.ans", "r"), nil repeat diff --git a/halyde/lib/filesystem.lua b/halyde/lib/filesystem.lua index c058af4..3648bfd 100644 --- a/halyde/lib/filesystem.lua +++ b/halyde/lib/filesystem.lua @@ -235,8 +235,7 @@ function filesystem.rename(fromPath, toPath) if fromAddress == toAddress then return component.invoke(fromAddress, "rename", fromAbsPath, toAbsPath) else - local handle = component.invoke(fromAddress, "open", fromAbsPath, "r") - local data, tmpdata + local handle, data, tmpdata = component.invoke(fromAddress, "open", fromAbsPath, "r"), "", nil repeat tmpdata = component.invoke(fromAddress, "read", handle, math.huge or math.maxinteger) data = data .. (tmpdata or "")