diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-02-23 17:28:43 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-02-24 11:33:49 +0100 |
commit | 74a18f64eebc8f6f66d64e439e152c6cdf9d76db (patch) | |
tree | 34f6d3223027600f2023897124753179bd74176c /jurt | |
parent | 670c2b3ca99c9ae4a75c508408023de198e3ac5e (diff) |
cid#1326440 Dereference null return value
...replacing implicit NullPointerException with explicit RuntimeException
Change-Id: I14dfe81a6a05d33cb311a6274c085ea0dcf95692
Diffstat (limited to 'jurt')
-rw-r--r-- | jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java b/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java index 48d7630dd7e2..93a56b460b21 100644 --- a/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java +++ b/jurt/com/sun/star/lib/uno/protocols/urp/Unmarshal.java @@ -112,6 +112,10 @@ final class Unmarshal { public TypeDescription readType() { int b = read8Bit(); TypeClass typeClass = TypeClass.fromInt(b & 0x7F); + if (typeClass == null) { + throw new RuntimeException( + "Reading TYPE with bad type class " + (b & 0x7F)); + } if (TypeDescription.isTypeClassSimple(typeClass)) { return TypeDescription.getTypeDescription(typeClass); } else { |