summaryrefslogtreecommitdiffstats
path: root/sys-utils/dmesg.c
diff options
context:
space:
mode:
authorKarel Zak2018-02-13 10:52:57 +0100
committerKarel Zak2018-02-13 10:52:57 +0100
commitdd83526ae3c85c2af62922c5e5fa15b4652f382f (patch)
tree87a859f878bbb234b98cf5e1eaf79406ed006aa8 /sys-utils/dmesg.c
parenttests: update build-sys tests (diff)
downloadkernel-qcow2-util-linux-dd83526ae3c85c2af62922c5e5fa15b4652f382f.tar.gz
kernel-qcow2-util-linux-dd83526ae3c85c2af62922c5e5fa15b4652f382f.tar.xz
kernel-qcow2-util-linux-dd83526ae3c85c2af62922c5e5fa15b4652f382f.zip
dmesg: use xstrdup() in xalloc.h based util
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'sys-utils/dmesg.c')
-rw-r--r--sys-utils/dmesg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys-utils/dmesg.c b/sys-utils/dmesg.c
index ad47ac44d..0e2fad658 100644
--- a/sys-utils/dmesg.c
+++ b/sys-utils/dmesg.c
@@ -1016,7 +1016,7 @@ mesg_output:
*/
if (ctl->force_prefix) {
if (!line) {
- mesg_copy = strdup(rec->mesg);
+ mesg_copy = xstrdup(rec->mesg);
line = strtok(mesg_copy, "\n");
mesg_size = strlen(line);
}