Commit 3815ebcc by Gaurav Singh

containertests: fix null pointer defereference

parent ebe4f04e
...@@ -135,7 +135,7 @@ int main(int argc, char *argv[]) ...@@ -135,7 +135,7 @@ int main(int argc, char *argv[])
str = c->config_file_name(c); str = c->config_file_name(c);
#define CONFIGFNAM LXCPATH "/" MYNAME "/config" #define CONFIGFNAM LXCPATH "/" MYNAME "/config"
if (!str || strcmp(str, CONFIGFNAM)) { if (str && strcmp(str, CONFIGFNAM)) {
fprintf(stderr, "%d: got wrong config file name (%s, not %s)\n", __LINE__, str, CONFIGFNAM); fprintf(stderr, "%d: got wrong config file name (%s, not %s)\n", __LINE__, str, CONFIGFNAM);
goto out; goto out;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment