Commit 8154d06315c627afc89ad40e76113a5d9ed17c40

Authored by Mumfrey
1 parent 9174b3b0

Fix crash reporting

src/main/java/com/mumfrey/liteloader/core/LiteLoader.java
... ... @@ -32,9 +32,9 @@ import com.mumfrey.liteloader.common.LoadingProgress;
32 32 import com.mumfrey.liteloader.core.api.LiteLoaderCoreAPI;
33 33 import com.mumfrey.liteloader.core.event.EventProxy;
34 34 import com.mumfrey.liteloader.core.event.HandlerList;
35   -import com.mumfrey.liteloader.crashreport.CallableLaunchWrapper;
36   -import com.mumfrey.liteloader.crashreport.CallableLiteLoaderBrand;
37   -import com.mumfrey.liteloader.crashreport.CallableLiteLoaderMods;
  35 +import com.mumfrey.liteloader.crashreport.CrashSectionLaunchWrapper;
  36 +import com.mumfrey.liteloader.crashreport.CrashSectionLiteLoaderBrand;
  37 +import com.mumfrey.liteloader.crashreport.CrashSectionLiteLoaderMods;
38 38 import com.mumfrey.liteloader.interfaces.FastIterableDeque;
39 39 import com.mumfrey.liteloader.interfaces.Loadable;
40 40 import com.mumfrey.liteloader.interfaces.LoadableMod;
... ... @@ -1022,9 +1022,9 @@ public final class LiteLoader
1022 1022 private static void populateCrashReport(CrashReport crashReport)
1023 1023 {
1024 1024 CrashReportCategory category = crashReport.getCategory(); // crashReport.makeCategoryDepth("Mod System Details", 1);
1025   - category.addCrashSection("Mod Pack", new CallableLiteLoaderBrand(crashReport));
1026   - category.addCrashSection("LiteLoader Mods", new CallableLiteLoaderMods(crashReport));
1027   - category.addCrashSection("LaunchWrapper", new CallableLaunchWrapper(crashReport));
  1025 + category.addCrashSection("LiteLoader Brand", new CrashSectionLiteLoaderBrand(crashReport));
  1026 + category.addCrashSection("LiteLoader Mods", new CrashSectionLiteLoaderMods(crashReport));
  1027 + category.addCrashSection("LaunchWrapper", new CrashSectionLaunchWrapper(crashReport));
1028 1028 }
1029 1029  
1030 1030 static final void createInstance(LoaderEnvironment environment, LoaderProperties properties, LaunchClassLoader classLoader)
... ...
src/main/java/com/mumfrey/liteloader/crashreport/CallableLaunchWrapper.java renamed to src/main/java/com/mumfrey/liteloader/crashreport/CrashSectionLaunchWrapper.java
... ... @@ -12,22 +12,22 @@ import net.minecraft.crash.CrashReport;
12 12 import net.minecraft.launchwrapper.IClassTransformer;
13 13 import net.minecraft.launchwrapper.Launch;
14 14  
15   -public class CallableLaunchWrapper implements Callable<String>
  15 +public class CrashSectionLaunchWrapper
16 16 {
17 17 final CrashReport crashReport;
18 18  
19   - public CallableLaunchWrapper(CrashReport report)
  19 + public CrashSectionLaunchWrapper(CrashReport report)
20 20 {
21 21 this.crashReport = report;
22 22 }
23 23  
24 24 /* (non-Javadoc)
25   - * @see java.util.concurrent.Callable#call()
  25 + * @see java.lang.Object#toString()
26 26 */
27 27 @Override
28   - public String call() throws Exception
  28 + public String toString()
29 29 {
30   - return CallableLaunchWrapper.generateTransformerList();
  30 + return CrashSectionLaunchWrapper.generateTransformerList();
31 31 }
32 32  
33 33 /**
... ...
src/main/java/com/mumfrey/liteloader/crashreport/CallableLiteLoaderBrand.java renamed to src/main/java/com/mumfrey/liteloader/crashreport/CrashSectionLiteLoaderBrand.java
... ... @@ -5,26 +5,24 @@
5 5 */
6 6 package com.mumfrey.liteloader.crashreport;
7 7  
8   -import java.util.concurrent.Callable;
9   -
10 8 import com.mumfrey.liteloader.core.LiteLoader;
11 9  
12 10 import net.minecraft.crash.CrashReport;
13 11  
14   -public class CallableLiteLoaderBrand implements Callable<String>
  12 +public class CrashSectionLiteLoaderBrand
15 13 {
16 14 final CrashReport crashReport;
17 15  
18   - public CallableLiteLoaderBrand(CrashReport report)
  16 + public CrashSectionLiteLoaderBrand(CrashReport report)
19 17 {
20 18 this.crashReport = report;
21 19 }
22 20  
23 21 /* (non-Javadoc)
24   - * @see java.util.concurrent.Callable#call()
  22 + * @see java.lang.Object#toString()
25 23 */
26 24 @Override
27   - public String call() throws Exception
  25 + public String toString()
28 26 {
29 27 String brand = null;
30 28 try
... ...
src/main/java/com/mumfrey/liteloader/crashreport/CallableLiteLoaderMods.java renamed to src/main/java/com/mumfrey/liteloader/crashreport/CrashSectionLiteLoaderMods.java
... ... @@ -5,26 +5,24 @@
5 5 */
6 6 package com.mumfrey.liteloader.crashreport;
7 7  
8   -import java.util.concurrent.Callable;
9   -
10 8 import com.mumfrey.liteloader.core.LiteLoader;
11 9  
12 10 import net.minecraft.crash.CrashReport;
13 11  
14   -public class CallableLiteLoaderMods implements Callable<String>
  12 +public class CrashSectionLiteLoaderMods
15 13 {
16 14 final CrashReport crashReport;
17 15  
18   - public CallableLiteLoaderMods(CrashReport report)
  16 + public CrashSectionLiteLoaderMods(CrashReport report)
19 17 {
20 18 this.crashReport = report;
21 19 }
22 20  
23 21 /* (non-Javadoc)
24   - * @see java.util.concurrent.Callable#call()
  22 + * @see java.lang.Object#toString()
25 23 */
26 24 @Override
27   - public String call() throws Exception
  25 + public String toString()
28 26 {
29 27 try
30 28 {
... ...