modprobe-small: trivial SEGV fix

This commit is contained in:
Denis Vlasenko 2008-09-14 20:33:03 +00:00
parent 0d602e9386
commit 7c9c1bb616

View File

@ -600,7 +600,7 @@ static void process_module(char *name, const char *cmdline_options)
free(deps);
/* modprobe -> load it */
if (!is_rmmod && !strstr(options, "blacklist")) {
if (!is_rmmod && (options && !strstr(options, "blacklist"))) {
errno = 0;
if (load_module(info->pathname, options) != 0) {
if (EEXIST != errno) {