From a105780c45f03d65cd973e5311c5760dd1941812 Mon Sep 17 00:00:00 2001
From: "alexey.stratulat" <alexey.stratulat@demlabs.net>
Date: Wed, 8 Jan 2020 21:49:00 +0700
Subject: [PATCH] [*] The error SEGFAULT in function addProc is fixed.

---
 include/wrapping_dap_enc_http.h | 2 ++
 src/wrapping_dap_enc_http.c     | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/include/wrapping_dap_enc_http.h b/include/wrapping_dap_enc_http.h
index 1c2f26fa..85fe1728 100644
--- a/include/wrapping_dap_enc_http.h
+++ b/include/wrapping_dap_enc_http.h
@@ -3,6 +3,8 @@
 
 #include <Python.h>
 #include "dap_server_python.h"
+#include "dap_enc_http.h"
+#include "dap_http.h"
 
 typedef struct PyDapEncHttp{
     PyObject_HEAD
diff --git a/src/wrapping_dap_enc_http.c b/src/wrapping_dap_enc_http.c
index 54ddc8ca..e20c26f5 100644
--- a/src/wrapping_dap_enc_http.c
+++ b/src/wrapping_dap_enc_http.c
@@ -5,6 +5,6 @@ PyObject *enc_http_add_proc_py(PyObject *self, PyObject *args){
     const char *HTTP_URL;
     if (!PyArg_ParseTuple(args, "O|s", &obj_server, &HTTP_URL))
         return NULL;
-    enc_http_add_proc_py(((PyDapServerObject*)obj_server)->t_server, HTTP_URL);
+    enc_http_add_proc(DAP_HTTP(((PyDapServerObject*)obj_server)->t_server), HTTP_URL);
     return PyLong_FromLong(0);
 }
-- 
GitLab