Drivers specified on the command line (-d) override any specified in

the configuration file.
This commit is contained in:
ddouthitt
2001-09-28 00:06:27 +00:00
parent 214c957726
commit ad5de5bb17
+4 -2
View File
@@ -267,8 +267,10 @@ main (int argc, char **argv)
} else {
// not in a driver section...
if (strncasecmp(linebuf, "Driver ", 7) == 0) {
driverlist[list_index] = malloc(MAX_DRIVER_NAME_SIZE);
snprintf(driverlist[list_index++], MAX_DRIVER_NAME_SIZE, "%s", linebuf + 7);
if (driverlist[0] == NULL) { // check for arguments: override conf file drivers...
driverlist[list_index] = malloc(MAX_DRIVER_NAME_SIZE);
snprintf(driverlist[list_index++], MAX_DRIVER_NAME_SIZE, "%s", linebuf + 7);
}
}
}
}