Skip to content

Commit

Permalink
bootloader: Fix debug print for 32/64 bit ELF
Browse files Browse the repository at this point in the history
  • Loading branch information
JonathonReinhart committed Sep 28, 2020
1 parent 579ec0b commit 814020d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bootloader/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <stdint.h>
#include <inttypes.h>
#include <string.h>
#include <errno.h>
#include <assert.h>
Expand Down Expand Up @@ -160,7 +162,8 @@ set_rpath(Elf_Ehdr *ehdr, const char *new_rpath)
error(2, 0, "RPATH outside of dynamic strtab!");
char *rpath = ptr_add(dynstrtab, dt_rpath->d_un.d_val);

debug_printf("Current RPATH (0x%lX): \"%s\"\n", dt_rpath->d_un.d_val,
debug_printf("Current RPATH (0x%"PRIXPTR"): \"%s\"\n",
(uintptr_t)dt_rpath->d_un.d_val,
fmt_str_rep(rpath));

/* Set new RPATH */
Expand Down

0 comments on commit 814020d

Please sign in to comment.