Browse Source

纠正乱码

tags/v1.0.0^2
林万龙 3 years ago
parent
commit
db82f068b4
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      src/main/java/com/telpo/dipperposition/common/SocketClient.java

+ 3
- 1
src/main/java/com/telpo/dipperposition/common/SocketClient.java View File

@@ -4,6 +4,8 @@ import lombok.extern.slf4j.Slf4j;

import java.io.*;
import java.net.Socket;
import java.nio.charset.StandardCharsets;

/**
* @program: dipperposition
* @description: socket连接单元
@@ -50,7 +52,7 @@ public class SocketClient {
String reply=null;
//输入流
InputStream is=socket.getInputStream();
BufferedReader br=new BufferedReader(new InputStreamReader(is));
BufferedReader br=new BufferedReader(new InputStreamReader(is, StandardCharsets.UTF_8));

String ackResult="";
String ackHexOut = HexConvert.convertStringToHex(ackAckCheckRef);


Loading…
Cancel
Save