diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-10-15 10:23:35 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-10-15 11:38:56 +0100 |
commit | 4f4667da482e5b8b4552bab55db66c81bdc17015 (patch) | |
tree | ef8f68dfb3067b88f5a4bfaf5a53a051548e1256 /qadevOOo/tests/java/ifc/i18n | |
parent | abe51680360ad0d7fc67862b80f406d484bcf0a4 (diff) |
coverity#1326287 Explicit null dereferenced
Change-Id: I6b2f8beb25cb5743db9d5f0b92dfce723c6d89e5
Diffstat (limited to 'qadevOOo/tests/java/ifc/i18n')
-rw-r--r-- | qadevOOo/tests/java/ifc/i18n/_XExtendedCalendar.java | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/qadevOOo/tests/java/ifc/i18n/_XExtendedCalendar.java b/qadevOOo/tests/java/ifc/i18n/_XExtendedCalendar.java index 99d26e7b9a0b..bd190241c1a6 100644 --- a/qadevOOo/tests/java/ifc/i18n/_XExtendedCalendar.java +++ b/qadevOOo/tests/java/ifc/i18n/_XExtendedCalendar.java @@ -39,17 +39,13 @@ public class _XExtendedCalendar extends MultiMethodTest { * Load a calendar */ @Override - public void before() { + public void before() throws Exception { Locale[] installed_locales = null; - XLocaleData locData = null; - try { - locData = UnoRuntime.queryInterface( - XLocaleData.class, - tParam.getMSF().createInstance( - "com.sun.star.i18n.LocaleData")); - } catch (com.sun.star.uno.Exception e) { + XLocaleData locData = UnoRuntime.queryInterface( + XLocaleData.class, + tParam.getMSF().createInstance( + "com.sun.star.i18n.LocaleData")); - } installed_locales = locData.getAllInstalledLocaleNames(); // use first Locale as fallback, if US-English is not found Locale lo = installed_locales[0]; |