mirror of https://github.com/OpenVPN/openvpn-gui
Mark status as connected only if openvpn reports CONNECTED,SUCCESS
Avoid reporting a connection that completed with errors (state change message = CONNECTED,ERROR) as successful. Signed-off-by: Selva Nair <selva.nair@gmail.com>pull/112/head
parent
d82471d927
commit
91b3eef40a
|
@ -191,7 +191,7 @@ OnStateChange(connection_t *c, char *data)
|
||||||
return;
|
return;
|
||||||
*pos = '\0';
|
*pos = '\0';
|
||||||
|
|
||||||
if (strcmp(state, "CONNECTED") == 0)
|
if (strcmp(state, "CONNECTED") == 0 && strcmp(message, "SUCCESS") == 0)
|
||||||
{
|
{
|
||||||
/* Run Connect Script */
|
/* Run Connect Script */
|
||||||
if (c->state == connecting || c->state == resuming)
|
if (c->state == connecting || c->state == resuming)
|
||||||
|
|
Loading…
Reference in New Issue