Fix the setXXXStream methods. If passed a null InputStream, convert
authorKris Jurka <books@ejurka.com>
Tue, 3 Feb 2004 05:13:56 +0000 (05:13 +0000)
committerKris Jurka <books@ejurka.com>
Tue, 3 Feb 2004 05:13:56 +0000 (05:13 +0000)
commit822d2bc63277eb55d38b58a1a45bebfaeb658eb4
tree4875810c9fa8481fdd8144edefbd438652205acb
parentec35ef19655b9e9781f75f4240d0830723ee41e4
Fix the setXXXStream methods.  If passed a null InputStream, convert
this to a setNull call.  The code originally would try to read the
whole stream in one call to read(), but this doesn't work.  The
InputStream API makes it clear you must be prepared to loop and
continue reading if you didn't get the whole request on the first
try.

Per report from Martin Holz.
src/interfaces/jdbc/org/postgresql/jdbc1/AbstractJdbc1Statement.java
src/interfaces/jdbc/org/postgresql/test/jdbc2/Jdbc2TestSuite.java
src/interfaces/jdbc/org/postgresql/test/jdbc2/PreparedStatementTest.java [new file with mode: 0644]