]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Back ported patches from head to 7.3 branch (fixes for NPE in result set absolute...
authorBarry Lind <barry@xythos.com>
Sat, 8 Mar 2003 06:09:37 +0000 (06:09 +0000)
committerBarry Lind <barry@xythos.com>
Sat, 8 Mar 2003 06:09:37 +0000 (06:09 +0000)
 Modified Files:
  Tag: REL7_3_STABLE
  jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java
  jdbc/org/postgresql/util/PSQLException.java

src/interfaces/jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java
src/interfaces/jdbc/org/postgresql/util/PSQLException.java

index 6ce4ed4b03394e69b0ccd78d173c651b4adf115e..26515c361c9213e4fd3725fb6e18f33db935f5b0 100644 (file)
@@ -15,7 +15,7 @@ import org.postgresql.util.PGbytea;
 import org.postgresql.util.PSQLException;
 
 
-/* $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/jdbc2/Attic/AbstractJdbc2ResultSet.java,v 1.10.2.1 2003/02/24 16:38:25 barry Exp $
+/* $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/jdbc2/Attic/AbstractJdbc2ResultSet.java,v 1.10.2.2 2003/03/08 06:09:37 barry Exp $
  * This class defines methods of the jdbc2 specification.  This class extends
  * org.postgresql.jdbc1.AbstractJdbc1ResultSet which provides the jdbc1
  * methods.  The real Statement class (for jdbc2) is org.postgresql.jdbc2.Jdbc2ResultSet
@@ -188,6 +188,10 @@ public abstract class AbstractJdbc2ResultSet extends org.postgresql.jdbc1.Abstra
 
                current_row = internalIndex;
                this_row = (byte[][]) rows.elementAt(internalIndex);
+
+               rowBuffer = new byte[this_row.length][];
+               System.arraycopy(this_row, 0, rowBuffer, 0, this_row.length);
+
                return true;
        }
 
index 46c71fab11fb1750968c77d873f0086113d0a93a..309306bb26a856eedb02ae58debf46b56bdb3644 100644 (file)
@@ -111,6 +111,6 @@ public class PSQLException extends SQLException
         */
        public String toString()
        {
-               return message;
+               return message != null ? message : "";
        }
 }