1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-22 17:35:59 +03:00

Make sure dereferenced words[0] and words[1] are defined

This commit is contained in:
Zdenek Kabelac 2012-02-13 14:17:04 +00:00
parent 07d54dd4a7
commit 27d46fc686
2 changed files with 3 additions and 1 deletions

View File

@ -1,5 +1,6 @@
Version 1.02.71 -
====================================
Test for parsed words in _umount() dmeventd snapshot plugin.
Fix memory leak in fail path of parse_loop_device_name() in dmsetup.
Check for missing reply_uuid in dm_event_get_registered_device().
Check for allocation failure in dmeventd restart().

View File

@ -144,7 +144,8 @@ static void _umount(const char *device, int major, int minor)
break; /* eof, likely */
/* words[0] is the mount point and words[1] is the device path */
dm_split_words(buffer, 3, 0, words);
if (dm_split_words(buffer, 3, 0, words) < 2)
continue;
/* find the major/minor of the device */
if (stat(words[0], &st))