const char *prefix = buf;
snprintf(buf, sizeof(buf), "#%d ", idx);
+ buf[sizeof(buf) - 1] = '\0';
if(req->flags != arch_irn_flags_none) {
fprintf(f, "%sflags: ", prefix);
int ret_status;
snprintf(cmd_line, sizeof(cmd_line), "%s -i %s -o %s", prog_to_call, out_file, result_file);
+ cmd_line[sizeof(cmd_line) - 1] = '\0';
ret_status = system(cmd_line);
assert(ret_status != -1 && "Invokation of external register allocator failed");
if (! e) {
char buf[64];
snprintf(buf, sizeof(buf), "spill_slot_type_%s", get_mode_name(ss->largest_mode));
+ buf[sizeof(buf) - 1] = '\0';
res = new_type_primitive(new_id_from_str(buf), ss->largest_mode);
set_type_alignment_bytes(res, ss->align);
pmap_insert(types, ss->largest_mode, res);
/* build entity */
snprintf(buf, sizeof(buf), "spill_slot_%d", i);
+ buf[sizeof(buf) - 1] = '\0';
name = new_id_from_str(buf);
spill_ent = new_entity(frame, name, get_spill_type(ssenv->types, ss[i]));
}
snprintf(buf, sizeof(buf), "-%02d%s", nr++, suffix);
+ buf[sizeof(buf) - 1] = '\0';
dumper(irg, buf);
}
char buf[1024];
snprintf(buf, sizeof(buf), "%s.%s", base, ext);
+ buf[sizeof(buf) - 1] = '\0';
if (! (out = fopen(buf, mode))) {
fprintf(stderr, "Cannot open file %s in mode %s\n", buf, mode);
return NULL;