sshnet: don't leak error string
This commit is contained in:
parent
81f3b1a233
commit
7a3ceb58fc
1 changed files with 4 additions and 5 deletions
|
@ -1103,12 +1103,11 @@ handlemsg(Msg *m)
|
|||
break;
|
||||
}
|
||||
c = getclient(chan);
|
||||
if(c == nil || c->state != Dialing){
|
||||
free(s);
|
||||
break;
|
||||
if(c != nil && c->state == Dialing){
|
||||
c->state = Closed;
|
||||
hangupclient(c, s);
|
||||
}
|
||||
c->state = Closed;
|
||||
hangupclient(c, s);
|
||||
free(s);
|
||||
break;
|
||||
}
|
||||
free(m);
|
||||
|
|
Loading…
Reference in a new issue