Check for unused constructors too
This commit is contained in:
@@ -59,10 +59,10 @@ public class Deob
|
|||||||
new UnusedBlocks().run(group);
|
new UnusedBlocks().run(group);
|
||||||
|
|
||||||
// remove unused parameters
|
// remove unused parameters
|
||||||
new UnusedParameters().run(group);
|
//new UnusedParameters().run(group);
|
||||||
|
|
||||||
// remove jump obfuscation
|
// remove jump obfuscation
|
||||||
new Jumps().run(group);
|
//new Jumps().run(group);
|
||||||
|
|
||||||
// remove unused fields
|
// remove unused fields
|
||||||
new UnusedFields().run(group);
|
new UnusedFields().run(group);
|
||||||
|
|||||||
@@ -24,8 +24,9 @@ public class UnusedMethods implements Deobfuscator
|
|||||||
{
|
{
|
||||||
for (Method m : new ArrayList<>(cf.getMethods().getMethods()))
|
for (Method m : new ArrayList<>(cf.getMethods().getMethods()))
|
||||||
{
|
{
|
||||||
/* assume obfuscated names are <= 2 chars */
|
// assume obfuscated names are <= 2 chars
|
||||||
if (m.getName().length() > 2)
|
// constructors can be unused, too
|
||||||
|
if (m.getName().length() > 2 && !m.getName().equals("<init>"))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (!execution.methods.contains(m))
|
if (!execution.methods.contains(m))
|
||||||
|
|||||||
Reference in New Issue
Block a user