Skip to content
Snippets Groups Projects
Commit 0c608b70 authored by alexey.stratulat's avatar alexey.stratulat
Browse files

[*] He returned dap_common initialization and added two parameters to...

[*] He returned dap_common initialization and added two parameters to initialize the module. Accordingly, I modified the test file to verify the changes.
parent dd39f109
No related branches found
No related tags found
1 merge request!26Support 3689
......@@ -4,9 +4,14 @@
static PyObject *dap_server_core_init(PyObject *self, PyObject *args){
uint32_t l_thread_cnt;
size_t conn_t;
if (!PyArg_ParseTuple(args, "I|n", &l_thread_cnt, &conn_t)){
const char *app_name;
const char *app_log;
if (!PyArg_ParseTuple(args, "I|n|s|s", &l_thread_cnt, &conn_t, &app_name, &app_log)){
return NULL;
}
int32_t result_common_init = dap_common_init(app_name, app_log);
if (result_common_init != 0)
return PyLong_FromLong(result_common_init);
int32_t result = dap_server_init(l_thread_cnt);
if ( result != 0 ) {
log_it( L_CRITICAL, "Can't init socket server module" );
......
import libDapServerCore as server
print ("Start wrapping libdap server core python module")
res_i = server.init(1, 0)
res_i = server.init(1, 0, "TestServer", "TestServer.txt")
rc = server.listen("0.0.0.0", 3307, 0)
server.deinit()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment