Only servers can register to sessions
This commit is contained in:
parent
cfbcac054c
commit
ce9a56a0fc
|
@ -313,6 +313,9 @@ int apptransport_server_register(AppTransport * transport, char const * app)
|
||||||
int ret;
|
int ret;
|
||||||
int res = -1;
|
int res = -1;
|
||||||
|
|
||||||
|
if(transport->mode != ATM_SERVER)
|
||||||
|
return -error_set_code(1, "%s",
|
||||||
|
"Only servers can register to sessions");
|
||||||
if(transport->appclient != NULL)
|
if(transport->appclient != NULL)
|
||||||
appclient_delete(transport->appclient);
|
appclient_delete(transport->appclient);
|
||||||
if((transport->appclient = appclient_new("Session", NULL)) == NULL)
|
if((transport->appclient = appclient_new("Session", NULL)) == NULL)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user