&& integer_declaration->p.alignment == CHAR_BIT) {
uint64_t len = bt_sequence_len(sequence_definition);
- ctf_align_pos(pos, integer_declaration->p.alignment);
+ if (!ctf_align_pos(pos, integer_declaration->p.alignment))
+ return -EFAULT;
if (!ctf_pos_access_ok(pos, len * CHAR_BIT))
return -EFAULT;
g_string_assign(sequence_definition->string, "");
g_string_insert_len(sequence_definition->string,
0, (char *) ctf_get_pos_addr(pos), len);
- ctf_move_pos(pos, len * CHAR_BIT);
+ if (!ctf_move_pos(pos, len * CHAR_BIT))
+ return -EFAULT;
return 0;
}
}
&& integer_declaration->p.alignment == CHAR_BIT) {
uint64_t len = bt_sequence_len(sequence_definition);
- ctf_align_pos(pos, integer_declaration->p.alignment);
+ if (!ctf_align_pos(pos, integer_declaration->p.alignment))
+ return -EFAULT;
if (!ctf_pos_access_ok(pos, len * CHAR_BIT))
return -EFAULT;
memcpy((char *) ctf_get_pos_addr(pos),
sequence_definition->string->str, len);
- ctf_move_pos(pos, len * CHAR_BIT);
+ if (!ctf_move_pos(pos, len * CHAR_BIT))
+ return -EFAULT;
return 0;
}
}