diff options
Diffstat (limited to 'libdm/libdm-string.c')
-rw-r--r-- | libdm/libdm-string.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libdm/libdm-string.c b/libdm/libdm-string.c index 0e41f9d9d..c6f101bcc 100644 --- a/libdm/libdm-string.c +++ b/libdm/libdm-string.c @@ -93,7 +93,7 @@ static char *_unquote(char *component) int dm_split_lvm_name(struct dm_pool *mem, const char *dmname, char **vgname, char **lvname, char **layer) { - if (!(*vgname = dm_pool_strdup(mem, dmname))) + if (mem && !(*vgname = dm_pool_strdup(mem, dmname))) return 0; _unquote(*layer = _unquote(*lvname = _unquote(*vgname))); |