File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
app/src/main/java/com/wmods/wppenhacer/xposed/features/general Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change 8
8
import com .wmods .wppenhacer .xposed .core .Feature ;
9
9
import com .wmods .wppenhacer .xposed .core .devkit .Unobfuscator ;
10
10
11
+ import java .util .ArrayList ;
11
12
import java .util .Collection ;
12
13
import java .util .Iterator ;
13
14
import java .util .LinkedHashMap ;
@@ -50,6 +51,17 @@ protected void beforeHookedMethod(MethodHookParam param) throws Throwable {
50
51
}
51
52
});
52
53
54
+ // Fix bug in initialCapacity of ArrayList
55
+ XposedHelpers .findAndHookConstructor (ArrayList .class , int .class , new XC_MethodHook () {
56
+ @ Override
57
+ protected void beforeHookedMethod (MethodHookParam param ) throws Throwable {
58
+ if ((int ) param .args [0 ] < 0 ) {
59
+ param .args [0 ] = Math .abs ((int ) param .args [0 ]);
60
+ }
61
+ }
62
+ });
63
+
64
+
53
65
// This creates a modified linkedhashMap to return 0 if the fixed list is less than 60.
54
66
XposedBridge .hookMethod (pinnedSetMethod , new XC_MethodHook () {
55
67
You can’t perform that action at this time.
0 commit comments