diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/amd64/amd64/intr.c | 2 | ||||
-rw-r--r-- | sys/include/arch/amd64/intr.h | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/sys/arch/amd64/amd64/intr.c b/sys/arch/amd64/amd64/intr.c index 9f70e88..cb38cd8 100644 --- a/sys/arch/amd64/amd64/intr.c +++ b/sys/arch/amd64/amd64/intr.c @@ -106,7 +106,7 @@ intr_register(const char *name, const struct intr_hand *ih) } /* Allocate memory for the name */ - name_len = strlen(name); + name_len = strlen(name) + 1; ih_new->name = dynalloc(name_len); if (ih_new->name == NULL) { dynfree(ih_new); diff --git a/sys/include/arch/amd64/intr.h b/sys/include/arch/amd64/intr.h index 5e3f397..b640e4b 100644 --- a/sys/include/arch/amd64/intr.h +++ b/sys/include/arch/amd64/intr.h @@ -60,6 +60,8 @@ * @irq: Interrupt request number [o] * @vector: Interrupt vector [v] * + * XXX: `name' must be null terminated ('\0') + * * XXX: `irq` can be set to -1 for MSI/MSI-X * interrupts. * |