[hg] main-silver: #206835: NPE at o.n.lib.ddl.adaptors.DefaultAd...

  • From: Jaroslav Havlin < >
  • To:
  • Subject: [hg] main-silver: #206835: NPE at o.n.lib.ddl.adaptors.DefaultAd...
  • Date: Mon, 28 Jan 2013 14:36:43 -0800

changeset 00eb8db06c53 in main-silver ((none))
details: http://hg.netbeans.org/main-silver/rev/00eb8db06c53
description:
        #206835: NPE at 
o.n.lib.ddl.adaptors.DefaultAdaptor.getDatabaseProductName

diffstat:

 db/libsrc/org/netbeans/lib/ddl/adaptors/DefaultAdaptor.java |  7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diffs (17 lines):

diff --git a/db/libsrc/org/netbeans/lib/ddl/adaptors/DefaultAdaptor.java 
b/db/libsrc/org/netbeans/lib/ddl/adaptors/DefaultAdaptor.java
--- a/db/libsrc/org/netbeans/lib/ddl/adaptors/DefaultAdaptor.java
+++ b/db/libsrc/org/netbeans/lib/ddl/adaptors/DefaultAdaptor.java
@@ -502,8 +502,11 @@
     {
         String product = (String)properties.get(PROP_PRODUCTNAME);
         if (product == null) {
-            if (dmd != null) product = dmd.getDatabaseProductName().trim();
-            else return NOT_SET_STRING;
+            if (dmd != null && dmd.getDatabaseProductName() != null) {
+                product = dmd.getDatabaseProductName().trim();
+            } else {
+                return NOT_SET_STRING;
+            }
             properties.put(PROP_PRODUCTNAME, product);
         }
 

[hg] main-silver: #206835: NPE at o.n.lib.ddl.adaptors.DefaultAd...

Jaroslav Havlin 01/28/2013

Project Features

About this Project

DB was started in November 2009, is owned by Antonin Nebuzelsky, and has 113 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20140418.2d69abc). © 2013, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
 
 
Close
loading
Please Confirm
Close