minor fix on error handling

This commit is contained in:
lxsang
2020-08-09 13:04:20 +02:00
parent d2aa1f3557
commit bd2c19d09a
5 changed files with 17 additions and 2 deletions

Binary file not shown.

View File

@@ -357,6 +357,13 @@ int main(int argc, char** argv)
if(msg.data)
free(msg.data);
}
else
{
M_ERROR(MODULE_NAME, "Channel is not created: %s. Tunnel service responds with msg of type %d", MODULE_NAME, msg.header.type);
if(msg.data)
free(msg.data);
running = 0;
}
// now read data
while(running)