Fix 2 findbugs encoding warnings in VmwareContext.java StreamReaders should use encoding specified in the connection object

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

This closes #405
This commit is contained in:
Rafael da Fonseca 2015-06-14 12:31:06 +02:00 committed by Rohit Yadav
parent 00cdd66351
commit f03411ca04

View File

@ -357,7 +357,7 @@ public class VmwareContext {
} }
out.flush(); out.flush();
br = new BufferedReader(new InputStreamReader(conn.getInputStream())); br = new BufferedReader(new InputStreamReader(conn.getInputStream(),conn.getContentEncoding()));
String line; String line;
while ((line = br.readLine()) != null) { while ((line = br.readLine()) != null) {
if (s_logger.isTraceEnabled()) if (s_logger.isTraceEnabled())
@ -483,7 +483,7 @@ public class VmwareContext {
out.write(content); out.write(content);
out.flush(); out.flush();
BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream())); BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream(),conn.getContentEncoding()));
String line; String line;
while ((line = in.readLine()) != null) { while ((line = in.readLine()) != null) {
if (s_logger.isTraceEnabled()) if (s_logger.isTraceEnabled())