Skip to content

Commit fbd3ce3

Browse files
committed
add more clarity to error when encoding to utf-8
1 parent da8e574 commit fbd3ce3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/marklogic/client/io/ReaderHandle.java

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ public void write(OutputStream out) throws IOException {
224224
byteBuf.clear();
225225
CoderResult result = encoder.encode(charBuf, byteBuf, false);
226226
if (result.isError()) {
227-
throw new IOException(result.toString());
227+
throw new IOException("Failed during UTF-8 encoding - " + result.toString());
228228
}
229229
byteBuf.flip();
230230
out.write(buf, 0, byteBuf.limit());

0 commit comments

Comments
 (0)