1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

libdm: check for empty aux_data in _parse_aux_data_group()

If after extracting stats arguments and group tags nothing remains
of aux_data but '-' set the region->aux_data field to the empty
string to match behaviour for non-grouped regions.
This commit is contained in:
Bryn M. Reeves 2016-07-06 16:29:06 +01:00
parent c1a66d4fc6
commit bf1dfea393

View File

@ -692,7 +692,7 @@ static int _parse_aux_data_group(struct dm_stats *dms,
}
/* separate group tag from user aux_data */
if (strlen(end))
if ((strlen(end) > 1) || strncmp(end, "-", 1))
c = dm_strdup(end);
else
c = dm_strdup("");