diff --git a/docs/install.md b/docs/install.md index a68b5b606..8a8ce855f 100644 --- a/docs/install.md +++ b/docs/install.md @@ -228,11 +228,13 @@ as far as possible automatically, but can be overridden by passing > [!IMPORTANT] > For successful compilation of this application, it's crucial that the build environment is equipped with a minimum of 1GB of memory and an additional 1GB of swap space. To verify your system's swap space availability, you can use the `swapon` command. Ensuring these requirements are met is vital for the application's compilation process. +> [!NOTE] +> The 'configure' step will detect the correct version of LDC to be used when compiling the client under ARMHF and ARM64 cpu architectures. + ```text git clone https://github.com/abraunegg/onedrive.git cd onedrive -./configure DC=/usr/bin/ldmd2 -make clean; make +./configure; make clean; make; sudo make install ``` diff --git a/src/sync.d b/src/sync.d index a7a5a70e3..9e751ca80 100644 --- a/src/sync.d +++ b/src/sync.d @@ -8470,6 +8470,9 @@ class SyncEngine { void processForInterruptedSessionUploads() { // For each upload_session file that has been found, process the data to ensure it is still valid foreach (sessionFilePath; interruptedUploadsSessionFiles) { + // What session data are we trying to restore + if (verboseLogging) {addLogEntry("Attempting to restore file upload session using this session data file: " ~ sessionFilePath, ["verbose"]);} + // Does this pass validation? if (!validateUploadSessionFileData(sessionFilePath)) { // Remove upload_session file as it is invalid // upload_session file file contains an error - cant resume this session @@ -8508,7 +8511,14 @@ class SyncEngine { // Try and read the text from the session file as a JSON array try { - sessionFileData = readText(sessionFilePath).parseJSON(); + if (getSize(sessionFilePath) > 0) { + // There is data to read in + sessionFileData = readText(sessionFilePath).parseJSON(); + } else { + // No data to read in - invalid file + if (debugLogging) {addLogEntry("SESSION-RESUME: Invalid JSON file: " ~ sessionFilePath, ["debug"]);} + return false; + } } catch (JSONException e) { if (debugLogging) {addLogEntry("SESSION-RESUME: Invalid JSON data in: " ~ sessionFilePath, ["debug"]);} return false;