[Soot-list] Issue while generating Dava code from class

Trishul Pani Mukherjee trishulpani at gmail.com
Tue Apr 1 09:14:58 EDT 2014


Hi,

I'm using Eclipse Keplar with Soot Eclipse Plugin 2.5.2.
While generating Dava class by Soot -> Dava Decompile App for the following
code, I'm getting an exception as given below:

[Code under test]

 public boolean isSupervisorResponsibleForUser(int dbId, String department)
{
        if (dbId == 0) {
            throw new IllegalArgumentException("A dbId is required");
        }
        if (department == null) {
            throw new IllegalArgumentException("department is required");
        }
        boolean hasUsers = false;

        if ( supervisorDao.getUserCountForSupervisor(dbId, department) > 0
        || supervisorDao.getName() != null    ){
            hasUsers = true;
        }
        return hasUsers;
    }

[Exception]

Decompiling main.java.com.cts.testgen.service.SupervisorService...
java.lang.reflect.InvocationTargetException
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
 at ca.mcgill.sable.soot.launching.SootThread.run(SootThread.java:138)
Caused by: java.lang.RuntimeException: Cannot compute SCCs for graph with
number of heads = 2
 at
soot.toolkits.graph.StronglyConnectedComponentsFast.<init>(StronglyConnectedComponentsFast.java:62)
at
soot.dava.toolkits.base.finders.CycleFinder.build_component_list(CycleFinder.java:220)
 at soot.dava.toolkits.base.finders.CycleFinder.find(CycleFinder.java:52)
at soot.dava.DavaBody.<init>(DavaBody.java:323)
 at soot.dava.Dava.newBody(Dava.java:84)
at soot.PackManager.runBodyPacks(PackManager.java:814)
at soot.PackManager.runBodyPacks(PackManager.java:463)
 at soot.PackManager.runBodyPacks(PackManager.java:380)
at soot.PackManager.runPacks(PackManager.java:357)
 at soot.Main.run(Main.java:198)
at soot.Main.main(Main.java:141)
... 5 more


However, Jimple & Grimp IRs are generated successfully.

Any reason why this is happening?


Thanks,

Trishul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20140401/07925462/attachment.html 


More information about the Soot-list mailing list