diff --git a/WHATS_NEW b/WHATS_NEW index 8dba1ffa2..7bdaaf26a 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,5 +1,6 @@ Version 2.02.89 - ================================== + Fix log_error() usage in raid and unknown segtype initialisation. Improve testing Makefile. Fix install_ocf make target when srcdir != builddir. (2.02.80) Support env vars LVM_CLVMD_BINARY and LVM_BINARY in clvmd. diff --git a/lib/raid/raid.c b/lib/raid/raid.c index 8bc334400..c3fc4b13c 100644 --- a/lib/raid/raid.c +++ b/lib/raid/raid.c @@ -338,7 +338,7 @@ static struct segment_type *_init_raid_segtype(struct cmd_context *cmd, if (!segtype) { log_error("Failed to allocate memory for %s segtype", raid_type); - return_NULL; + return NULL; } segtype->cmd = cmd; diff --git a/lib/unknown/unknown.c b/lib/unknown/unknown.c index de449bfe0..8f5c8096c 100644 --- a/lib/unknown/unknown.c +++ b/lib/unknown/unknown.c @@ -94,8 +94,10 @@ struct segment_type *init_unknown_segtype(struct cmd_context *cmd, const char *n { struct segment_type *segtype = dm_zalloc(sizeof(*segtype)); - if (!segtype) - return_NULL; + if (!segtype) { + log_error("Failed to allocate memory for unknown segtype"); + return NULL; + } segtype->cmd = cmd; segtype->ops = &_unknown_ops;