summaryrefslogtreecommitdiff
path: root/src/interfaces/jdbc/org/postgresql/PG_Stream.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfaces/jdbc/org/postgresql/PG_Stream.java')
-rw-r--r--src/interfaces/jdbc/org/postgresql/PG_Stream.java11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/interfaces/jdbc/org/postgresql/PG_Stream.java b/src/interfaces/jdbc/org/postgresql/PG_Stream.java
index 9a85df8a25..11781dba96 100644
--- a/src/interfaces/jdbc/org/postgresql/PG_Stream.java
+++ b/src/interfaces/jdbc/org/postgresql/PG_Stream.java
@@ -10,7 +10,7 @@ import org.postgresql.core.*;
import org.postgresql.util.*;
/*
- * $Id: PG_Stream.java,v 1.16 2001/11/19 23:16:45 momjian Exp $
+ * $Id: PG_Stream.java,v 1.17 2002/08/20 04:26:02 barry Exp $
*
* This class is used by Connection & PGlobj for communicating with the
* backend.
@@ -25,9 +25,6 @@ public class PG_Stream
private BufferedOutputStream pg_output;
private byte[] byte_buf = new byte[8*1024];
- BytePoolDim1 bytePoolDim1 = new BytePoolDim1();
- BytePoolDim2 bytePoolDim2 = new BytePoolDim2();
-
/*
* Constructor: Connect to the PostgreSQL back end and return
* a stream connection.
@@ -69,7 +66,7 @@ public class PG_Stream
*/
public void SendInteger(int val, int siz) throws IOException
{
- byte[] buf = bytePoolDim1.allocByte(siz);
+ byte[] buf = new byte[siz];
while (siz-- > 0)
{
@@ -272,7 +269,7 @@ public class PG_Stream
{
int i, bim = (nf + 7) / 8;
byte[] bitmask = Receive(bim);
- byte[][] answer = bytePoolDim2.allocByte(nf);
+ byte[][] answer = new byte[nf][0];
int whichbit = 0x80;
int whichbyte = 0;
@@ -310,7 +307,7 @@ public class PG_Stream
*/
private byte[] Receive(int siz) throws SQLException
{
- byte[] answer = bytePoolDim1.allocByte(siz);
+ byte[] answer = new byte[siz];
Receive(answer, 0, siz);
return answer;
}