endpoints in the server config; new/delete functions for the server config

This commit is contained in:
Infinity95
2017-08-10 19:00:32 +02:00
committed by Julius Pfrommer
parent 03369fda5e
commit a8012d3040
47 changed files with 615 additions and 626 deletions
+4 -8
View File
@@ -102,19 +102,15 @@ int main(void) {
signal(SIGINT, stopHandler);
signal(SIGTERM, stopHandler);
UA_ServerConfig config = UA_ServerConfig_standard;
UA_ServerNetworkLayer nl =
UA_ServerNetworkLayerTCP(UA_ConnectionConfig_standard, 16664);
config.networkLayers = &nl;
config.networkLayersSize = 1;
UA_ServerConfig *config = UA_ServerConfig_new_default();
UA_Server *server = UA_Server_new(config);
addVariable(server);
writeVariable(server);
writeWrongVariable(server);
UA_Server_run(server, &running);
UA_StatusCode retval = UA_Server_run(server, &running);
UA_Server_delete(server);
nl.deleteMembers(&nl);
return 0;
UA_ServerConfig_delete(config);
return (int)retval;
}