]> git.ipfire.org Git - thirdparty/util-linux.git/commit
include/xalloc: ensure xstrdup() and xstrndup() returns nonnull attribute
authorSami Kerola <kerolasa@iki.fi>
Fri, 12 Jul 2019 21:28:10 +0000 (22:28 +0100)
committerSami Kerola <kerolasa@iki.fi>
Sun, 14 Jul 2019 10:52:13 +0000 (11:52 +0100)
commitf3aded3fdb1e19818b05f205b74cd4bff7532811
treed96f40e8f6a1cdc7d51c28743be07dd51a7347c8
parent371be858d74fe5562a403af75e596d7bd0042905
include/xalloc: ensure xstrdup() and xstrndup() returns nonnull attribute

Turned out lsblk is passing null as argument to xstrdup(), so fix that and
add assert() to make sure promise of not returning null is kept in future.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
include/xalloc.h
misc-utils/lsblk.c