diff --git a/client/DialDiscovery.cpp b/client/DialDiscovery.cpp index 3d04c39..5297b2e 100644 --- a/client/DialDiscovery.cpp +++ b/client/DialDiscovery.cpp @@ -314,7 +314,7 @@ void *DialDiscovery::send_mcast() int one = 1, my_sock; socklen_t addrlen; //struct ip_mreq mreq; - char send_buf[strlen((char*)ssdp_msearch) + INET_ADDRSTRLEN + 256] = {0,}; + char send_buf[sizeof(ssdp_msearch) - 1 + INET_ADDRSTRLEN + 256] = {0,}; int send_size; search_conn connection;