src/os/linux/vm/attachListener_linux.cpp

changeset 485
485d403e94e1
parent 435
a61af66fc99e
child 631
d1605aabd0a1
equal deleted inserted replaced
484:31000d79ec71 485:485d403e94e1
230 // The request is: 230 // The request is:
231 // <ver>0<cmd>0<arg>0<arg>0<arg>0 231 // <ver>0<cmd>0<arg>0<arg>0<arg>0
232 // where <ver> is the protocol version (1), <cmd> is the command 232 // where <ver> is the protocol version (1), <cmd> is the command
233 // name ("load", "datadump", ...), and <arg> is an argument 233 // name ("load", "datadump", ...), and <arg> is an argument
234 int expected_str_count = 2 + AttachOperation::arg_count_max; 234 int expected_str_count = 2 + AttachOperation::arg_count_max;
235 int max_len = (strlen(ver_str) + 1) + (AttachOperation::name_length_max + 1) + 235 const int max_len = (sizeof(ver_str) + 1) + (AttachOperation::name_length_max + 1) +
236 AttachOperation::arg_count_max*(AttachOperation::arg_length_max + 1); 236 AttachOperation::arg_count_max*(AttachOperation::arg_length_max + 1);
237 237
238 char buf[max_len]; 238 char buf[max_len];
239 int str_count = 0; 239 int str_count = 0;
240 240

mercurial