diff options
author | aclement <aclement> | 2010-06-29 00:07:59 +0000 |
---|---|---|
committer | aclement <aclement> | 2010-06-29 00:07:59 +0000 |
commit | 92a52a21be71734cfe05dc6a8fdbc8a14beba467 (patch) | |
tree | 2096633c33c59f32d336e24a01db6021bf646ea0 /weaver/src/org | |
parent | d0670c44eb69aeae547e2028b7ff629f2f0b0cb3 (diff) | |
download | aspectj-92a52a21be71734cfe05dc6a8fdbc8a14beba467.tar.gz aspectj-92a52a21be71734cfe05dc6a8fdbc8a14beba467.zip |
317139: guard on NPE
Diffstat (limited to 'weaver/src/org')
-rw-r--r-- | weaver/src/org/aspectj/weaver/bcel/BcelObjectType.java | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelObjectType.java b/weaver/src/org/aspectj/weaver/bcel/BcelObjectType.java index 8f1826c1b..a78aab81d 100644 --- a/weaver/src/org/aspectj/weaver/bcel/BcelObjectType.java +++ b/weaver/src/org/aspectj/weaver/bcel/BcelObjectType.java @@ -819,10 +819,13 @@ public class BcelObjectType extends AbstractReferenceTypeDelegate { if (isGeneric()) { // update resolved typex to point at generic type not raw type. ReferenceType genericType = (ReferenceType) this.resolvedTypeX.getGenericType(); - // genericType.setSourceContext(this.resolvedTypeX.getSourceContext() - // ); - genericType.setStartPos(this.resolvedTypeX.getStartPos()); - this.resolvedTypeX = genericType; + // genericType.setSourceContext(this.resolvedTypeX.getSourceContext()); + // Can be null if unpacking whilst building the bcel delegate (in call hierarchy from BcelWorld.addSourceObjectType() + // line 453) - see 317139 + if (genericType != null) { + genericType.setStartPos(this.resolvedTypeX.getStartPos()); + this.resolvedTypeX = genericType; + } } } |