mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-15 00:44:19 +09:00
serial: fix memory leak in case of error out.
This commit is contained in:
@@ -450,6 +450,7 @@ BOOL serial_tty_read(SERIAL_TTY* tty, BYTE* buffer, UINT32* Length)
|
||||
|
||||
tcsetattr(tty->fd, TCSANOW, ptermios);
|
||||
tty->timeout = timeout;
|
||||
free(ptermios);
|
||||
}
|
||||
|
||||
ZeroMemory(buffer, *Length);
|
||||
|
||||
Reference in New Issue
Block a user