Fix potential attach order bug when attaching a serial port to a single line mux found by Dave Bryan
This commit is contained in:
parent
30c70f6866
commit
122ca9b7cd
1 changed files with 1 additions and 1 deletions
|
@ -1641,7 +1641,7 @@ while (*tptr) {
|
|||
serport = sim_open_serial (destination, lp, &r);
|
||||
if (serport != INVALID_HANDLE) {
|
||||
_mux_detach_line (lp, TRUE, TRUE);
|
||||
if (lp->mp->master) { /* if existing listener, close it */
|
||||
if (lp->mp && lp->mp->master) { /* if existing listener, close it */
|
||||
sim_close_sock (lp->mp->master, 1);
|
||||
lp->mp->master = 0;
|
||||
free (lp->mp->port);
|
||||
|
|
Loading…
Add table
Reference in a new issue