Re: binary data - Mailing list pgsql-jdbc

From Anders Hermansen
Subject Re: binary data
Date
Msg-id 20030302143730.GA19602@online.no
Whole thread Raw
In response to Re: binary data  ("Uwe Kubosch" <donv@crusaders.no>)
Responses Re: binary data
List pgsql-jdbc
* Uwe Kubosch (donv@crusaders.no) wrote:
> This is a web-application that streams the InpuStream back to the browser.
> The code that does this is like this:
>
> byte[] buffer;
> int bytesRead;
>
> buffer = new byte[is.available()];
>
> while (is.available() > 0) {
>   bytesRead = is.read(buffer);
>   response.getOutputStream().write(buffer, 0, bytesRead);
> }
>
> response.getOutputStream().flush();
> is.close();

I can't see anything in your code that is not binary safe, or I'm
missing something obvious just like you. Maybe the gurus know.


Anders

--
Anders Hermansen
YoYo Mobile as

pgsql-jdbc by date:

Previous
From: "Uwe Kubosch"
Date:
Subject: Re: binary data
Next
From: "Uwe Kubosch"
Date:
Subject: Re: binary data