[Soot-list] Bug in exception handling?

Bodden, Eric eric.bodden at sit.fraunhofer.de
Tue Mar 11 08:01:37 EDT 2014


Hi Marc-Andre.

Yes I think we have seen this before. It is indeed caused by the new syntax. Can you please check whether this is already in the bug tracker and add it otherwise?

Cheers,
Eric

On 10.03.2014, at 18:14, Marc-André Laverdière <marc-andre.laverdiere-papineau at polymtl.ca> wrote:

> Hello Sooters,
> 
> I got a weird exception loading the bytecode from a method body (it is
> precompiled and from a FLOSS project I am not too familiar with)
> 
> java.lang.RuntimeException: Exception reference used other than as the
> first statement of an exception handler.
> 	at
> soot.jimple.toolkits.typing.fast.AugEvalFunction.eval_(AugEvalFunction.java:160)
> 	at ...
> soot.coffi.CoffiMethodSource.getBody(CoffiMethodSource.java:117)
> 	at soot.SootMethod.getBodyFromMethodSource(SootMethod.java:87)
> 
> The corresponding code snippet:
> String newId = null;
> try {
>    String latestId = new DocumentRevisionDAO(new
> Locale(user.getLanguage()), em).findLatestDocMId(pWorkspaceId,
> template.getDocumentType());
>    String inputMask = template.getMask();
>    String convertedMask = Tools.convertMask(inputMask);
>    newId = Tools.increaseId(latestId, convertedMask);
> } catch (ParseException | NoResultException ex) {
>    //may happen when a different mask has been used for the same
> document type
>    //or
>    //may happen when no document of the specified type has been created
> }
> 
> This form is new in Java 7.
> http://docs.oracle.com/javase/7/docs/technotes/guides/language/catch-multiple.html
> 
> This looks like a bug to me, but I'm not familiar with that piece of
> code. Would anybody confirm?
> 
> Regards,
> 
> -- 
> Marc-André Laverdière-Papineau
> Doctorant - PhD Candidate
> _______________________________________________
> Soot-list mailing list
> Soot-list at sable.mcgill.ca
> http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list

--
Prof. Eric Bodden, Ph.D., http://sse.ec-spride.de/ http://bodden.de/
Head of Secure Software Engineering  at Fraunhofer SIT, TU Darmstadt and EC SPRIDE
Tel: +49 6151 16-75422    Fax: +49 6151 16-72051
Room 3.2.14, Mornewegstr. 30, 64293 Darmstadt

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 841 bytes
Desc: Message signed with OpenPGP using GPGMail
Url : http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20140311/3d2ab7a3/attachment-0001.bin 


More information about the Soot-list mailing list