diff options
author | dimitri staessens <[email protected]> | 2016-07-08 13:34:38 +0200 |
---|---|---|
committer | dimitri staessens <[email protected]> | 2016-07-08 13:41:22 +0200 |
commit | f224dbb901842b021e231e4f3d7c42e62babcdb3 (patch) | |
tree | 35c55d50cea6e77c23bf63472ad95f755846c145 /src/lib | |
parent | 00dba20de7462c07866d321597697456a0ae8555 (diff) | |
download | ouroboros-f224dbb901842b021e231e4f3d7c42e62babcdb3.tar.gz ouroboros-f224dbb901842b021e231e4f3d7c42e62babcdb3.zip |
ipcpd: Deprecate ipcp_reg/ipcp_unreg
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/ipcp.c | 65 | ||||
-rw-r--r-- | src/lib/ipcpd_messages.proto | 14 |
2 files changed, 6 insertions, 73 deletions
diff --git a/src/lib/ipcp.c b/src/lib/ipcp.c index b0e593e4..3fd31f37 100644 --- a/src/lib/ipcp.c +++ b/src/lib/ipcp.c @@ -193,71 +193,6 @@ int ipcp_destroy(pid_t api) return 0; } -int ipcp_reg(pid_t api, - char ** dif_names, - size_t len) -{ - ipcp_msg_t msg = IPCP_MSG__INIT; - ipcp_msg_t * recv_msg = NULL; - int ret = -1; - - if (dif_names == NULL || - len == 0 || - dif_names[0] == NULL) - return -EINVAL; - - msg.code = IPCP_MSG_CODE__IPCP_REG; - msg.dif_names = dif_names; - msg.len = len; - - recv_msg = send_recv_ipcp_msg(api, &msg); - if (recv_msg == NULL) - return -1; - - if (recv_msg->has_result == false) { - ipcp_msg__free_unpacked(recv_msg, NULL); - return -1; - } - - ret = recv_msg->result; - ipcp_msg__free_unpacked(recv_msg, NULL); - - return ret; -} - -int ipcp_unreg(pid_t api, - char ** dif_names, - size_t len) -{ - ipcp_msg_t msg = IPCP_MSG__INIT; - ipcp_msg_t * recv_msg = NULL; - int ret = -1; - - if (dif_names == NULL || - len == 0 || - dif_names[0] == NULL) - return -EINVAL; - - msg.code = IPCP_MSG_CODE__IPCP_UNREG; - msg.dif_names = dif_names; - msg.len = len; - - recv_msg = send_recv_ipcp_msg(api, &msg); - if (recv_msg == NULL) - return -1; - - if (recv_msg->has_result == false) { - ipcp_msg__free_unpacked(recv_msg, NULL); - return -1; - } - - ret = recv_msg->result; - ipcp_msg__free_unpacked(recv_msg, NULL); - - return ret; -} - - int ipcp_bootstrap(pid_t api, dif_config_msg_t * conf) { diff --git a/src/lib/ipcpd_messages.proto b/src/lib/ipcpd_messages.proto index f9e0f972..eb764e18 100644 --- a/src/lib/ipcpd_messages.proto +++ b/src/lib/ipcpd_messages.proto @@ -3,14 +3,12 @@ import "dif_config.proto"; enum ipcp_msg_code { IPCP_BOOTSTRAP = 1; IPCP_ENROLL = 2; - IPCP_REG = 3; - IPCP_UNREG = 4; - IPCP_NAME_REG = 5; - IPCP_NAME_UNREG = 6; - IPCP_FLOW_ALLOC = 7; - IPCP_FLOW_ALLOC_RESP = 8; - IPCP_FLOW_DEALLOC = 9; - IPCP_REPLY = 10; + IPCP_NAME_REG = 3; + IPCP_NAME_UNREG = 4; + IPCP_FLOW_ALLOC = 5; + IPCP_FLOW_ALLOC_RESP = 6; + IPCP_FLOW_DEALLOC = 7; + IPCP_REPLY = 8; }; message ipcp_msg { |