Fixes suggested by Valgrind tool
Fixes suggested by Valgrind tool
This commit is contained in:
@ -388,6 +388,7 @@ char task_name[BLRM_TASK_NAME_LEN+1] = "";
|
||||
else if (strcmp(options[i], "master_uuid") == 0)
|
||||
{
|
||||
inst->set_master_uuid = strdup(value);
|
||||
inst->master_uuid = inst->set_master_uuid;
|
||||
}
|
||||
else if (strcmp(options[i], "master_version") == 0)
|
||||
{
|
||||
@ -1329,7 +1330,8 @@ int len;
|
||||
return NULL;
|
||||
memcpy(rval, (char *)(errpkt->start) + 7, 6);
|
||||
rval[6] = ' ';
|
||||
memcpy(&rval[7], (char *)(errpkt->start) + 13, len - 8);
|
||||
/* message size is len - (1 byte field count + 2 bytes errno + 6 bytes status) */
|
||||
memcpy(&rval[7], (char *)(errpkt->start) + 13, len - 9);
|
||||
rval[len-2] = 0;
|
||||
return rval;
|
||||
}
|
||||
|
Reference in New Issue
Block a user