summaryrefslogtreecommitdiffstats
path: root/weaver/src/org
diff options
context:
space:
mode:
authoraclement <aclement>2010-06-29 00:07:59 +0000
committeraclement <aclement>2010-06-29 00:07:59 +0000
commit92a52a21be71734cfe05dc6a8fdbc8a14beba467 (patch)
tree2096633c33c59f32d336e24a01db6021bf646ea0 /weaver/src/org
parentd0670c44eb69aeae547e2028b7ff629f2f0b0cb3 (diff)
downloadaspectj-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.java11
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;
+ }
}
}