From 92187bc53dc7c177dbd41ea7a1ea8796b42db24f Mon Sep 17 00:00:00 2001 From: Daniel Markstedt Date: Sun, 30 Oct 2022 12:26:01 -0700 Subject: [PATCH] Null terminate string passed to stncpy --- partition_map.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/partition_map.c b/partition_map.c index 8808e8f..c78ef76 100644 --- a/partition_map.c +++ b/partition_map.c @@ -589,7 +589,7 @@ add_partition_to_map(const char *name, const char *dptype, uint32_t base, uint32 if (strstr(dptype, "Driver")) { // Assume 68k drivers for now - strncpy(cur->data->dpme_process_id, "68000", 5); + strncpy(cur->data->dpme_process_id, "68000\0", 6); Block0* bz = map->misc; if (bz->sbDrvrCount < sizeof(bz->sbMap) / sizeof(DDMap))