summaryrefslogtreecommitdiff
path: root/src/vconsole/vconsole-setup.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-01-12 16:03:48 +0100
committerLennart Poettering <lennart@poettering.net>2016-01-12 16:03:48 +0100
commit45630488f9dc510c0b9da1932c5046160e6871ec (patch)
tree43606871b8012973ac6f3936d4887a5c658ce097 /src/vconsole/vconsole-setup.c
parent1f52a79d4eb0216bf1f2d96539609f02d8bb9e71 (diff)
parentd054f0a4d451120c26494263fc4dc175bfd405b1 (diff)
Merge pull request #2308 from zonque/xsprintf
tree-wide: use xsprintf() where applicable
Diffstat (limited to 'src/vconsole/vconsole-setup.c')
-rw-r--r--src/vconsole/vconsole-setup.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/vconsole/vconsole-setup.c b/src/vconsole/vconsole-setup.c
index a5f4529cfd..622fbe9a6d 100644
--- a/src/vconsole/vconsole-setup.c
+++ b/src/vconsole/vconsole-setup.c
@@ -39,6 +39,7 @@
#include "log.h"
#include "process-util.h"
#include "signal-util.h"
+#include "stdio-util.h"
#include "string-util.h"
#include "terminal-util.h"
#include "util.h"
@@ -215,11 +216,11 @@ static void font_copy_to_all_vcs(int fd) {
continue;
/* skip non-allocated ttys */
- snprintf(vcname, sizeof(vcname), "/dev/vcs%i", i);
+ xsprintf(vcname, "/dev/vcs%i", i);
if (access(vcname, F_OK) < 0)
continue;
- snprintf(vcname, sizeof(vcname), "/dev/tty%i", i);
+ xsprintf(vcname, "/dev/tty%i", i);
vcfd = open_terminal(vcname, O_RDWR|O_CLOEXEC);
if (vcfd < 0)
continue;