summaryrefslogtreecommitdiff
path: root/connectivity
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-05-08 09:26:35 +0200
committerStephan Bergmann <sbergman@redhat.com>2015-05-08 09:49:02 +0200
commitc5e08b42ace5f4481c3db87b4fb6ae2dbf9d9a51 (patch)
tree8a936492c2ddc1538860407a18f4218a26199cbc /connectivity
parentfa54d73a59a87902a0054d12fa684197b1939b19 (diff)
I very much assume this wants to call java.io.Reader.ready
...seeing that there is no java.io.Reader.available. (And then, there's no good way to map from java.io.Reader.ready's boolean value to css.io.XInputStream.available's long value, so conservatively map true to 1.) But I have no idea how to trigger this code. Change-Id: I18d12e0d968141410a1b56e700ed544edceda97c
Diffstat (limited to 'connectivity')
-rw-r--r--connectivity/source/drivers/jdbc/Reader.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/connectivity/source/drivers/jdbc/Reader.cxx b/connectivity/source/drivers/jdbc/Reader.cxx
index a7cd3698c5a8..20db5108e8a5 100644
--- a/connectivity/source/drivers/jdbc/Reader.cxx
+++ b/connectivity/source/drivers/jdbc/Reader.cxx
@@ -57,19 +57,19 @@ void SAL_CALL java_io_Reader::skipBytes( sal_Int32 nBytesToSkip ) throw(::com::s
sal_Int32 SAL_CALL java_io_Reader::available( ) throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception)
{
- jboolean out(sal_False);
+ jboolean out;
SDBThreadAttach t; OSL_ENSURE(t.pEnv,"Java Enviroment geloescht worden!");
{
static const char * cSignature = "()Z";
- static const char * cMethodName = "available";
+ static const char * cMethodName = "ready";
// Java-Call
static jmethodID mID(NULL);
obtainMethodId_throwRuntime(t.pEnv, cMethodName,cSignature, mID);
out = t.pEnv->CallBooleanMethod( object, mID);
ThrowRuntimeException(t.pEnv,*this);
} //t.pEnv
- return out;
+ return out ? 1 : 0; // no way to tell *how much* is ready
}
void SAL_CALL java_io_Reader::closeInput( ) throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception)