Add default case to relocate function for x86_64

This commit is contained in:
herman ten brugge
2022-04-12 07:11:52 +02:00
parent c1725a8f6e
commit e86aae4f6d

View File

@@ -249,6 +249,9 @@ void relocate(TCCState *s1, ElfW_Rel *rel, int type, unsigned char *ptr, addr_t
}
break;
case R_X86_64_COPY:
break;
case R_X86_64_PLTOFF64:
add64le(ptr, val - s1->got->sh_addr + rel->r_addend);
break;
@@ -369,6 +372,10 @@ void relocate(TCCState *s1, ElfW_Rel *rel, int type, unsigned char *ptr, addr_t
#endif
/* do nothing */
break;
default:
fprintf(stderr,"FIXME: handle reloc type %d at %x [%p] to %x\n",
type, (unsigned)addr, ptr, (unsigned)val);
break;
}
}