From bf0f0deecbbcfa6f9f79970851c4a446aaf10a21 Mon Sep 17 00:00:00 2001 From: e507802 Date: Wed, 29 May 2019 15:49:37 +0200 Subject: [PATCH] fix regression from PR #221 when bootstrapping into an empty directory with -Dappbase parameter, the version must be read first from the configuration in order to create a valid appbase after re-reading the just downloaded getdown.txt (in verisoned mode) --- .../java/com/threerings/getdown/data/Application.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/core/src/main/java/com/threerings/getdown/data/Application.java b/core/src/main/java/com/threerings/getdown/data/Application.java index a1deca4..80ea812 100644 --- a/core/src/main/java/com/threerings/getdown/data/Application.java +++ b/core/src/main/java/com/threerings/getdown/data/Application.java @@ -594,7 +594,10 @@ public class Application * like the appbase and version. */ public void initBase (Config config) throws IOException { - // first determine our application base, this way if anything goes wrong later in the + // first extract our version information + _version = config.getLong("version", -1L); + + // determine our application base, this way if anything goes wrong later in the // process, our caller can use the appbase to download a new configuration file _appbase = config.getString("appbase"); if (_appbase == null) { @@ -609,9 +612,6 @@ public class Application _appbase += "/"; } - // extract our version information - _version = config.getLong("version", -1L); - // if we are a versioned deployment, create a versioned appbase try { _vappbase = createVAppBase(_version);