diff options
| author | joerg <joerg@NetBSD.org> | 2009-04-08 12:39:27 +0000 |
|---|---|---|
| committer | joerg <joerg@NetBSD.org> | 2009-04-08 12:39:27 +0000 |
| commit | 892f4bbba1b42eabb01a0e1c2905a3058d095d17 (patch) | |
| tree | b58b391c0c83db9c9fb939ab2eb164d18fe42d04 /sys/dev | |
| parent | 1b5f62901eb8586d41613300c5e2fabdc3574f0f (diff) | |
sprintf -> snprintf
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/acpi/acpi.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/dev/acpi/acpi.c b/sys/dev/acpi/acpi.c index b5ea62e023a..6ddfcb7f8ed 100644 --- a/sys/dev/acpi/acpi.c +++ b/sys/dev/acpi/acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi.c,v 1.124 2009/04/08 00:23:30 dyoung Exp $ */ +/* $NetBSD: acpi.c,v 1.125 2009/04/08 12:39:27 joerg Exp $ */ /*- * Copyright (c) 2003, 2007 The NetBSD Foundation, Inc. @@ -70,7 +70,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.124 2009/04/08 00:23:30 dyoung Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.125 2009/04/08 12:39:27 joerg Exp $"); #include "opt_acpi.h" #include "opt_pcifixup.h" @@ -519,7 +519,8 @@ acpi_attach(device_t parent, device_t self, void *aux) #endif acpi_build_tree(sc); - sprintf(acpi_supported_states, "%s%s%s%s%s%s", + snprintf(acpi_supported_states, sizeof(acpi_supported_states), + "%s%s%s%s%s%s", is_available_state(sc, ACPI_STATE_S0) ? "S0 " : "", is_available_state(sc, ACPI_STATE_S1) ? "S1 " : "", is_available_state(sc, ACPI_STATE_S2) ? "S2 " : "", |
