diff --git a/github b/github index 90d3a6c..a46f549 160000 --- a/github +++ b/github @@ -1 +1 @@ -Subproject commit 90d3a6c84c003ab42a3ecfb5197b9368897862b1 +Subproject commit a46f54984b7ad9721c01273e77807469cd2c63a9 diff --git a/jenkins/create_build.sh b/jenkins/create_build.sh index fcf2fe2..8fd81cd 100755 --- a/jenkins/create_build.sh +++ b/jenkins/create_build.sh @@ -124,4 +124,4 @@ function deploy_client() { #compile_scripts #compile_native package_client -#deploy_client +deploy_client diff --git a/modules/renderer/ClientStorage.ts b/modules/renderer/ClientStorage.ts index 10e62ba..f373740 100644 --- a/modules/renderer/ClientStorage.ts +++ b/modules/renderer/ClientStorage.ts @@ -21,6 +21,11 @@ export class ClientStorageAdapter implements StorageAdapter { const result = await fs.readFile(storageKeyPath(key)); return JSON.parse(result.toString()); } catch (error) { + if(error.code === "ENOENT") { + /* The file does not exists */ + return null; + } + logError(LogCategory.GENERAL, tr("Failed to load client storage key %s: %o"), key, error); return null; } diff --git a/modules/renderer/ClientUpdater.ts b/modules/renderer/ClientUpdater.ts index dfc3879..31d72be 100644 --- a/modules/renderer/ClientUpdater.ts +++ b/modules/renderer/ClientUpdater.ts @@ -136,7 +136,14 @@ export class ClientUpdater implements Updater { } getLastUsedVersion(): string { - return settings.getValue(Settings.KEY_UPDATER_LAST_USED_CLIENT, undefined); + const result = settings.getValue(Settings.KEY_UPDATER_LAST_USED_CLIENT, undefined); + if(result === undefined) { + /* We never have executed the client */ + this.updateUsedVersion(); + return this.getCurrentVersion(); + } + + return result; } updateUsedVersion() { diff --git a/native/updater/util.cpp b/native/updater/util.cpp index 3367457..a3a2873 100644 --- a/native/updater/util.cpp +++ b/native/updater/util.cpp @@ -15,7 +15,7 @@ using namespace std; return GetBinaryTypeA(file.c_str(), lpBinaryType); } - VOID execute_app(LPCTSTR lpApplicationName,LPSTR arguments) + void execute_app(LPCTSTR lpApplicationName,LPSTR arguments) { // additional information STARTUPINFO si; @@ -32,7 +32,7 @@ using namespace std; nullptr, // Process handle not inheritable nullptr, // Thread handle not inheritable FALSE, // Set handle inheritance to FALSE - CREATE_NEW_CONSOLE , // No creation flags + CREATE_DEFAULT_ERROR_MODE | CREATE_NEW_CONSOLE , // No creation flags nullptr, // Use parent's environment block nullptr, // Use parent's starting directory &si, // Pointer to STARTUPINFO structure diff --git a/package.json b/package.json index a861a07..9e73161 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "scripts": { "crash_handler": "electron . crash-handler", "test": "echo \"Error: no test specified\" && exit 1", - "start-download-dev": "electron . --disable-hardware-acceleration --gdb --debug --updater-ui-loader_type=0 -t -u https://clientapi.teaspeak.dev/", + "start-download-dev": "electron . --disable-hardware-acceleration --gdb --debug -t -u https://clientapi.teaspeak.dev/", "start-s": "electron . --disable-hardware-acceleration --gdb --debug --updater-ui-loader_type=3 --updater-ui-ignore-version -t -u http://localhost:8080/", "dtest": "electron . dtest", "sass": "sass",