aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/survive_api.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/survive_api.c b/src/survive_api.c
index a39524b..fb2459f 100644
--- a/src/survive_api.c
+++ b/src/survive_api.c
@@ -1,7 +1,8 @@
#include "survive_api.h"
+#include "inttypes.h"
#include "os_generic.h"
-#include "survive.h"
#include "stdio.h"
+#include "survive.h"
struct SurviveSimpleObject {
struct SurviveSimpleContext *actx;
@@ -69,7 +70,7 @@ struct SurviveSimpleContext *survive_simple_init(int argc, char *const *argv) {
obj->type = SurviveSimpleObject_LIGHTHOUSE;
obj->actx = actx;
obj->has_update = ctx->bsd[i].PositionSet;
- snprintf(obj->name, 32, "LH%ld", i);
+ snprintf(obj->name, 32, "LH%" PRIdPTR, i);
}
for (; i < object_ct; i++) {
struct SurviveSimpleObject *obj = &actx->objects[i];
@@ -91,7 +92,7 @@ int survive_simple_stop_thread(struct SurviveSimpleContext *actx) {
intptr_t error = (intptr_t)OGJoinThread(actx->thread);
if (error != 0) {
SurviveContext *ctx = actx->ctx;
- SV_INFO("Warning: Loope exited with error %ld", error);
+ SV_INFO("Warning: Loop exited with error %" PRIdPTR, error);
}
return error;
}