seL4platsupport: Use strtol instead of sscanf to parse hex
diff --git a/libsel4platsupport/src/bootinfo.c b/libsel4platsupport/src/bootinfo.c index 2906035..a011f33 100644 --- a/libsel4platsupport/src/bootinfo.c +++ b/libsel4platsupport/src/bootinfo.c
@@ -23,8 +23,8 @@ ZF_LOGE("Attempted %s in an environment without bootinfo.", __FUNCTION__); return NULL; } - void *bi; - if (sscanf(bi_string, "%p", &bi) != 1) { + void *bi = (void *)strtol(bi_string, NULL, 0); + if (bi == 0) { ZF_LOGE("bootinfo environment value '%s' was not valid.", bi_string); return NULL; }