Skip to content

Commit

Permalink
[imcc] fix .sub name last char
Browse files Browse the repository at this point in the history
  • Loading branch information
Reini Urban committed Oct 15, 2014
1 parent a08e4f8 commit 257b033
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion compilers/imcc/imcc.y
Expand Up @@ -759,7 +759,7 @@ mk_sub_address_fromc(ARGMOD(imc_info_t *imcc), ARGIN(const char *name))
}
else if (*name == '\'') {
name_copy = mem_sys_strdup(name+1);
name_copy[strlen(name) - 1] = 0;
name_copy[strlen(name_copy) - 1] = 0;
}
else {
name_copy = mem_sys_strdup(name);
Expand Down
2 changes: 1 addition & 1 deletion compilers/imcc/imcparser.c
Expand Up @@ -836,7 +836,7 @@ mk_sub_address_fromc(ARGMOD(imc_info_t *imcc), ARGIN(const char *name))
}
else if (*name == '\'') {
name_copy = mem_sys_strdup(name+1);
name_copy[strlen(name) - 1] = 0;
name_copy[strlen(name_copy) - 1] = 0;
}
else {
name_copy = mem_sys_strdup(name);
Expand Down
2 changes: 1 addition & 1 deletion compilers/imcc/symreg.c
Expand Up @@ -871,7 +871,7 @@ mk_const(ARGMOD(imc_info_t * imcc), ARGIN(const char *name), int t)
}

if (Interp_trace_TEST(imcc->interp, 8))
fprintf(stderr, "# mk_const '%s'\n", const_name);
fprintf(stderr, "# mk_const '%s' %c\n", const_name, t);
result = _mk_const(imcc, h, const_name, t);
if (encoded)
result->type |= VT_ENCODED;
Expand Down

0 comments on commit 257b033

Please sign in to comment.