capiinit/capiinit.c: use 'configure'd path for capi.conf
Look for capi.conf in the path determined by configure at compile time instead of the hard-coded /etc/capi.conf. Beautification: replace 0 -> NULL in firmwarepath[] definition.
This commit is contained in:
parent
deae31548f
commit
9c56a67d74
|
@ -88,6 +88,12 @@
|
||||||
#include <linux/kernelcapi.h>
|
#include <linux/kernelcapi.h>
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
|
|
||||||
|
#if defined(HAVE_CONFIG_H)
|
||||||
|
# include "config.h"
|
||||||
|
#else
|
||||||
|
# define I4LCONFDIR "/etc/isdn"
|
||||||
|
#endif
|
||||||
|
|
||||||
#define MODPROBE "/sbin/modprobe"
|
#define MODPROBE "/sbin/modprobe"
|
||||||
static char capidevnameold[] = "/dev/capi20";
|
static char capidevnameold[] = "/dev/capi20";
|
||||||
static char capidevnamenew[] = "/dev/isdn/capi20";
|
static char capidevnamenew[] = "/dev/isdn/capi20";
|
||||||
|
@ -98,7 +104,7 @@ static char *firmwarepath[] = {
|
||||||
"/usr/share/isdn",
|
"/usr/share/isdn",
|
||||||
"/usr/lib/isdn",
|
"/usr/lib/isdn",
|
||||||
"/lib/isdn",
|
"/lib/isdn",
|
||||||
0
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
/* ---------------- global variables --------------------------------- */
|
/* ---------------- global variables --------------------------------- */
|
||||||
|
@ -107,7 +113,7 @@ static int capifd = -1;
|
||||||
|
|
||||||
static int patchdebug = 0; /* -d || -debug */
|
static int patchdebug = 0; /* -d || -debug */
|
||||||
static int silent = 0; /* -s || -silent */
|
static int silent = 0; /* -s || -silent */
|
||||||
char *configfilename = "/etc/capi.conf";
|
char *configfilename = I4LCONFDIR "/capi.conf";
|
||||||
|
|
||||||
/* ---------------- utils -------------------------------------------- */
|
/* ---------------- utils -------------------------------------------- */
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue