Fix virtual serial port

This commit is contained in:
Nonoo 2020-10-27 17:27:39 +01:00
parent 303012fa56
commit afa48dc7a0
2 changed files with 4 additions and 4 deletions

View file

@ -48,8 +48,8 @@ func (s *serialPortStruct) writeLoop() {
func (s *serialPortStruct) readLoop() {
s.read = make(chan []byte)
b := make([]byte, maxSerialFrameLength)
for {
b := make([]byte, maxSerialFrameLength)
n, err := s.pty.Master.Read(b)
if err != nil {
if _, ok := err.(*os.PathError); !ok {