1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-02-03 17:47:44 +03:00

Fix potential NULL pointer dereference

Makes clang happier as it covers all code paths and avoids NULL pointer
dereference through the 'com' pointer (which is NULL by default static
initialisation).
This commit is contained in:
Zdenek Kabelac 2010-10-25 12:57:00 +00:00
parent b68cb6026e
commit 759241e905

View File

@ -85,11 +85,11 @@ static char *_list_args(const char *text, int state)
break;
}
}
if (!com)
return NULL;
}
if (!com)
return NULL;
/* Short form arguments */
if (len < 3) {
while (match_no < com->num_args) {