OSDN Git Service

Verify method invocation type.
authorAndy McFadden <fadden@android.com>
Sun, 10 Oct 2010 19:59:11 +0000 (12:59 -0700)
committerAndy McFadden <fadden@android.com>
Sun, 10 Oct 2010 21:04:42 +0000 (14:04 -0700)
commit5276cccb15b6ce0133c8107ff9ff013b4a176ef7
tree35e08cd5f08f61894993b23d69b35028b61a70fb
parent9be25d09d24b3d6d0dd1a41c1c09471af4827687
Verify method invocation type.

Dalvik provides five different ways to invoke a method (virtual, super,
direct, static, interface).  Using a virtual invoke instruction to call
a direct method will not produce the desired results.

This adds a test to the verifier that ensures the method targeted by
an invocation instruction is of an appropriate kind.

Bug 3082885.

(cherry-pick from dalvik-dev)

Change-Id: I3237cbefc7314f0b9d7557fc0bfd2b548ea30938
vm/analysis/CodeVerify.c