protocol: Fix memcpy build error

This commit is contained in:
Joshua Scott 2018-04-09 21:56:58 +01:00
parent 5ff4fb651d
commit 1755bda42e
1 changed files with 2 additions and 1 deletions

View File

@ -1,5 +1,6 @@
#include "ki/protocol/net/Participant.h" #include "ki/protocol/net/Participant.h"
#include "ki/protocol/exception.h" #include "ki/protocol/exception.h"
#include <cstring>
namespace ki namespace ki
{ {
@ -49,7 +50,7 @@ namespace net
((uint16_t *)packet_data)[1] = size; ((uint16_t *)packet_data)[1] = size;
// Copy the payload into the buffer and send it // Copy the payload into the buffer and send it
memcpy(&packet_data[4], data, size); std::memcpy(&packet_data[4], data, size);
send_packet_data(packet_data, size + 4); send_packet_data(packet_data, size + 4);
delete[] packet_data; delete[] packet_data;
} }