From 8af0370251ea6d79b5088dcf32272065cc0274f5 Mon Sep 17 00:00:00 2001 From: doudouCodingInGithub <96002450+doudouCodingInGithub@users.noreply.github.com> Date: Thu, 1 Jun 2023 18:29:25 +0800 Subject: [PATCH 1/2] Fix a ... problem(?) in launch.h Line 78 : add cwd before libraries I don't know whether this is a problem or bug but I think fix it is better ( ( ( --- include/river/launch.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/river/launch.h b/include/river/launch.h index 3c49cd5..cce3d95 100644 --- a/include/river/launch.h +++ b/include/river/launch.h @@ -75,7 +75,7 @@ int launchInstance(const char* versionId, const char* dir, RvG::Label* edi, RvG: free(tmpC); tmpC = NULL; join(libNameSp, libDir, 1024, "\\"); - strcpyf(tmpS, "libraries\\%s\\%s-%s.jar", libDir, libNameSp[1].asCString(), libNameSp[2].asCString()); + strcpyf(tmpS, "%slibraries\\%s\\%s-%s.jar", cwd, libDir, libNameSp[1].asCString(), libNameSp[2].asCString()); for (int i = 0; i < strlen(libDir); i++) { if (libDir[i] == '/') libDir[i] = '\\'; } @@ -369,4 +369,4 @@ int launchInstance(const char* versionId, const char* dir, RvG::Label* edi, RvG: }); thr.detach(); return 0; -} \ No newline at end of file +} From 44a30c4e9a00c7915a2be0e7ee0e5238917d510d Mon Sep 17 00:00:00 2001 From: doudouCodingInGithub <96002450+doudouCodingInGithub@users.noreply.github.com> Date: Thu, 1 Jun 2023 18:50:42 +0800 Subject: [PATCH 2/2] Fix another ... problem(?) in launch.h Line 108 : add cwd before libraries I don't know whether this is a problem or bug but I think fix it is better! ( ( ( --- include/river/launch.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/river/launch.h b/include/river/launch.h index cce3d95..2efdf9a 100644 --- a/include/river/launch.h +++ b/include/river/launch.h @@ -105,7 +105,7 @@ int launchInstance(const char* versionId, const char* dir, RvG::Label* edi, RvG: } if (tmpI == 0) continue; } - strcpyf(libDir, "libraries\\%s", versionLib["path"].asCString()); + strcpyf(libDir, "%slibraries\\%s", cwd, versionLib["path"].asCString()); for (int i = 0; i < strlen(libDir); i++) { if (libDir[i] == '/') libDir[i] = '\\'; }