| | |
| | | if (mtr_list_num > sizeof(mtr_list) / sizeof(mtr_list[0])) { |
| | | mtr_list_num = sizeof(mtr_list) / sizeof(mtr_list[0]); |
| | | } |
| | | |
| | | |
| | | Proc_ptr = &(ptr->procData); |
| | | for(int i = 0; i < mtr_list_num; i++) { |
| | | mtr_list[i].proc_id = ptr->procData.proc_id; |
| | | mtr_list[i].proc_id = (Proc_ptr + i)->proc_id; |
| | | mtr_list[i].mq_id = ID_RSV; |
| | | mtr_list[i].abs_addr = ABS_ID_RSV; |
| | | mtr_list[i].ip = "127.0.0.1"; |
| | |
| | | int sec, nsec; |
| | | std::string MsgID; |
| | | int timeout_ms = 3000; |
| | | char data_buf[MAX_STR_LEN] = { 0x00 }; |
| | | char buf_temp[MAX_STR_LEN] = { 0x00 }; |
| | | char *topics_buf = NULL; |
| | | |
| | |
| | | rv = net_mod_socket_reg(gNetmod_socket, buf_temp, strlen(buf_temp), &buf, &size, timeout_ms, PROC_QUE_STCS); |
| | | if (rv == 0) { |
| | | |
| | | val = atoi((char *)buf); |
| | | len = size > (sizeof(data_buf) - 1) ? (sizeof(data_buf) - 1) : size; |
| | | memcpy(data_buf, (char *)buf, len); |
| | | val = atoi((char *)data_buf); |
| | | |
| | | free(buf); |
| | | |
| | |
| | | net_node_t node; |
| | | int node_size; |
| | | int recv_arr_size; |
| | | char data_buf[MAX_STR_LEN] = { 0x00 }; |
| | | net_mod_recv_msg_t *recv_arr; |
| | | net_mod_err_t *errarr; |
| | | int errarr_size = 0; |
| | |
| | | rv = net_mod_socket_reg(gNetmod_socket, buf_temp, strlen(buf_temp), &buf, &size, timeout_ms, PROC_QUE_STCS); |
| | | if (rv == 0) { |
| | | |
| | | val = atoi((char *)buf); |
| | | len = size > (sizeof(data_buf) - 1) ? (sizeof(data_buf) - 1) : size; |
| | | memcpy(data_buf, (char *)buf, len); |
| | | val = atoi((char *)data_buf); |
| | | |
| | | free(buf); |
| | | |
| | |
| | | len += strlen(_input1.data); |
| | | #endif |
| | | |
| | | data = net_mod_socket_svr_get(gNetmod_socket); |
| | | topics_buf = (char *)malloc(len); |
| | | if (topics_buf == NULL) { |
| | | |