Skip to content

Commit 202c646

Browse files
committed
deactivate non-blocking Decoder => need to be fixed
1 parent 6b7100d commit 202c646

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

net.lecousin.core/src/main/java/net/lecousin/framework/io/text/Decoder.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,10 +93,10 @@ public int decode(char[] chars, int pos, int len, MutableBoolean interrupt, int
9393
int nb = 0;
9494
do {
9595
if (currentBuffer == null) {
96-
if (nextBuffer.isUnblocked())
96+
// TODO if (nextBuffer.isUnblocked())
9797
currentBuffer = nextBuffer.blockResult(0);
98-
else
99-
return nb > 0 ? nb : -2;
98+
// else
99+
// return nb > 0 ? nb : -2;
100100
if (currentBuffer != null)
101101
nextBuffer = io.readNextBufferAsync();
102102
}

net.lecousin.core/src/main/java/net/lecousin/framework/io/text/ProgressiveBufferedReadableCharStream.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -527,8 +527,8 @@ public Void run() throws CancelException {
527527
if (iNeedABuffer != null)
528528
iNeedABuffer.unblock();
529529
}
530+
taskFillBuffer = new TaskFillBuffer();
530531
}
531-
taskFillBuffer = new TaskFillBuffer();
532532
decoder.canDecode().listenAsync(taskFillBuffer, true);
533533
return null;
534534
}

0 commit comments

Comments
 (0)