diff options
author | Tor Lillqvist <tlillqvist@novell.com> | 2011-07-20 18:13:23 +0300 |
---|---|---|
committer | Tor Lillqvist <tlillqvist@novell.com> | 2011-07-20 18:14:05 +0300 |
commit | 44e18c3b9b15c30ff7330940dfbdd033de099caf (patch) | |
tree | 5da867ebf4e88137024e8638e729e25fbe7a2db8 /connectivity/source/drivers/hsqldb | |
parent | b9d3016fce6f0d2e06fc4c0f1183265a268f9dfc (diff) |
Add a few casts to fix MinGW compilation errors
Diffstat (limited to 'connectivity/source/drivers/hsqldb')
-rw-r--r-- | connectivity/source/drivers/hsqldb/HStorageAccess.cxx | 4 | ||||
-rw-r--r-- | connectivity/source/drivers/hsqldb/StorageNativeInputStream.cxx | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/connectivity/source/drivers/hsqldb/HStorageAccess.cxx b/connectivity/source/drivers/hsqldb/HStorageAccess.cxx index b102481b4fe3..0e2856a72e7a 100644 --- a/connectivity/source/drivers/hsqldb/HStorageAccess.cxx +++ b/connectivity/source/drivers/hsqldb/HStorageAccess.cxx @@ -257,7 +257,7 @@ jint read_from_storage_stream_into_buffer( JNIEnv * env, jobject /*obj_this*/,js if (nBytesRead <= 0) return -1; - env->SetByteArrayRegion(buffer,off,nBytesRead,&aData[0]); + env->SetByteArrayRegion(buffer,off,nBytesRead,(const jbyte*) &aData[0]); #ifdef HSQLDB_DBG if ( logger ) @@ -448,7 +448,7 @@ void write_to_storage_stream_from_buffer( JNIEnv* env, jobject /*obj_this*/, jst OSL_ENSURE(buf,"buf is NULL"); if ( buf && len > 0 && len <= env->GetArrayLength(buffer)) { - Sequence< ::sal_Int8 > aData(buf + off,len); + Sequence< ::sal_Int8 > aData((const signed char*) buf + off,len); env->ReleaseByteArrayElements(buffer, buf, JNI_ABORT); xOut->writeBytes(aData); #ifdef HSQLDB_DBG diff --git a/connectivity/source/drivers/hsqldb/StorageNativeInputStream.cxx b/connectivity/source/drivers/hsqldb/StorageNativeInputStream.cxx index 3fb691d5524a..1b13ed62c322 100644 --- a/connectivity/source/drivers/hsqldb/StorageNativeInputStream.cxx +++ b/connectivity/source/drivers/hsqldb/StorageNativeInputStream.cxx @@ -294,7 +294,7 @@ SAL_DLLPUBLIC_EXPORT jint JNICALL Java_com_sun_star_sdbcx_comp_hsqldb_StorageNat } OSL_ENSURE(nLen >= nBytesRead,"Buffer is too small!"); OSL_ENSURE(aData.getLength() >= nBytesRead,"Buffer is too small!"); - env->SetByteArrayRegion(buffer,0,nBytesRead,&aData[0]); + env->SetByteArrayRegion(buffer,0,nBytesRead,(const jbyte*) &aData[0]); #ifdef HSQLDB_DBG aDataLog.write( &aData[0], nBytesRead ); #endif |