diff options
Diffstat (limited to 'tools/console')
-rw-r--r-- | tools/console/daemon/io.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/console/daemon/io.c b/tools/console/daemon/io.c index 66db0f89cb..1a3f243a36 100644 --- a/tools/console/daemon/io.c +++ b/tools/console/daemon/io.c @@ -525,7 +525,8 @@ static int domain_create_ring(struct domain *dom) } else dom->use_consolepath = 0; - sprintf(path, "%s/type", dom->use_consolepath ? dom->conspath: dom->serialpath); + snprintf(path, sizeof(path), "%s/type", + dom->use_consolepath ? dom->conspath: dom->serialpath); type = xs_read(xs, XBT_NULL, path, NULL); if (type && strcmp(type, "xenconsoled") != 0) { free(type); |