Skip to content
This repository was archived by the owner on Sep 23, 2025. It is now read-only.

Commit dc479a2

Browse files
committed
Resolver changes
- Modified ResConfHack to read resolv data from the Java property - Added auto-unpacking of premade resolv.conf and setting the Java property (Now SRV resolving should work on Java 17 by default)
1 parent de50fd9 commit dc479a2

4 files changed

Lines changed: 5 additions & 1 deletion

File tree

Binary file not shown.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
nameserver 8.8.8.8
2+
nameserver 8.8.4.4

app_pojavlauncher/src/main/java/net/kdt/pojavlaunch/PojavLoginActivity.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ private void initMain() throws Throwable {
338338
Tools.copyAssetFile(this, "options.txt", Tools.DIR_GAME_NEW, false);
339339
// TODO: Remove after implement.
340340
Tools.copyAssetFile(this, "launcher_profiles.json", Tools.DIR_GAME_NEW, false);
341-
341+
Tools.copyAssetFile(this,"resolv.conf",Tools.DIR_DATA, true);
342342
AssetManager am = this.getAssets();
343343

344344
unpackComponent(am, "caciocavallo");

app_pojavlauncher/src/main/java/net/kdt/pojavlaunch/utils/JREUtils.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -346,6 +346,8 @@ public static List<String> getJavaArgs(Context ctx) {
346346
"-Dglfwstub.windowHeight=" + CallbackBridge.windowHeight,
347347
"-Dglfwstub.initEgl=false",
348348

349+
"-Dext.net.resolvPath=" +new File(Tools.DIR_DATA,"resolv.conf").getAbsolutePath(),
350+
349351
"-Dnet.minecraft.clientmodname=" + Tools.APP_NAME,
350352
"-Dfml.earlyprogresswindow=false" //Forge 1.14+ workaround
351353
};

0 commit comments

Comments
 (0)