|
|
|
@ -1,5 +1,5 @@ |
|
|
|
|
/* |
|
|
|
|
* Copyright 2000-2015 JetBrains s.r.o. |
|
|
|
|
* Copyright 2000-2016 JetBrains s.r.o. |
|
|
|
|
* |
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
@ -172,15 +172,13 @@ public class IrreducibleCFGDeobfuscator { |
|
|
|
|
|
|
|
|
|
private static int getStatementSize(Statement statement) { |
|
|
|
|
|
|
|
|
|
int res = 0; |
|
|
|
|
int res; |
|
|
|
|
|
|
|
|
|
if (statement.type == Statement.TYPE_BASICBLOCK) { |
|
|
|
|
res = ((BasicBlockStatement)statement).getBlock().getSeq().length(); |
|
|
|
|
} |
|
|
|
|
else { |
|
|
|
|
for (Statement stat : statement.getStats()) { |
|
|
|
|
res += getStatementSize(stat); |
|
|
|
|
} |
|
|
|
|
res = statement.getStats().stream().mapToInt(IrreducibleCFGDeobfuscator::getStatementSize).sum(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return res; |
|
|
|
|