diff --git a/avprogram/src/main/java/dvoraka/avservice/avprogram/ClamAvProgram.java b/avprogram/src/main/java/dvoraka/avservice/avprogram/ClamAvProgram.java index 260a0307..16a7209f 100644 --- a/avprogram/src/main/java/dvoraka/avservice/avprogram/ClamAvProgram.java +++ b/avprogram/src/main/java/dvoraka/avservice/avprogram/ClamAvProgram.java @@ -95,7 +95,7 @@ public String scanBytesNew(byte[] bytes) throws IOException { BufferedReader in = socket.getBufferedReader(); // send bytes - outStream.write("nINSTREAM\n".getBytes("UTF-8")); + outStream.write("nINSTREAM\n".getBytes(DEFAULT_CHARSET)); outStream.write(intBytes(bytes.length, CHUNK_LENGTH_BYTE_SIZE)); outStream.write(bytes); @@ -163,7 +163,7 @@ public String scanBytesWithInfo(byte[] bytes) throws ScanErrorException { BufferedReader in = new BufferedReader(inReader) ) { // send bytes - outStream.write("nINSTREAM\n".getBytes("UTF-8")); + outStream.write("nINSTREAM\n".getBytes(DEFAULT_CHARSET)); outStream.write(intBytes(bytes.length, CHUNK_LENGTH_BYTE_SIZE)); outStream.write(bytes);