Skip to content
Snippets Groups Projects
Commit 1b0a3c10 authored by dmitriy.gerasimov's avatar dmitriy.gerasimov
Browse files

Merge branch 'bug-undefined-behaviour' into 'master'

UB in App CLI

See merge request !84
parents 8b595920 eb375bc8
1 merge request!84UB in App CLI
......@@ -80,7 +80,7 @@ static void dap_app_cli_http_read(uint64_t *socket, dap_app_cli_cmd_state_t *l_c
if (l_str_ptr) {
l_str_ptr += strlen(l_head_end_str);
size_t l_head_size = l_str_ptr - l_cmd->cmd_res;
strncpy(l_cmd->cmd_res, l_str_ptr, l_cmd->cmd_res_cur - l_head_size);
memmove(l_cmd->cmd_res, l_str_ptr, l_cmd->cmd_res_cur - l_head_size);
l_cmd->cmd_res_cur -= l_head_size;
s_status++;
} else {
......
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