]> git.ipfire.org Git - people/ms/ipfire-3.x.git/blobdiff - ibod/patches/ibod-1.4-configuration-cli.patch
Remove support for ISDN
[people/ms/ipfire-3.x.git] / ibod / patches / ibod-1.4-configuration-cli.patch
diff --git a/ibod/patches/ibod-1.4-configuration-cli.patch b/ibod/patches/ibod-1.4-configuration-cli.patch
deleted file mode 100644 (file)
index 656d479..0000000
+++ /dev/null
@@ -1,74 +0,0 @@
-Author: Michael Tremer <michael.tremer@ipfire.org>
-
-diff -Nur ibod-1.4/ibod.c ibod-1.4-conf/ibod.c
---- ibod-1.4/ibod.c    2000-04-11 05:34:17.000000000 +0000
-+++ ibod-1.4-conf/ibod.c       2011-11-11 18:50:45.510054466 +0000
-@@ -23,7 +23,7 @@
- static void get_if_state();
- static int bring_up_slave();
- static int bring_down_slave();
--static char *home;
-+static char *config_file;
- static Conf cf;
- static struct timeval timeout, tv_last, tv_up;
- static int usageflags[ISDN_MAX_CHANNELS];
-@@ -48,12 +48,16 @@
-     channels_last = -1;
-+
-     /* Find out where to look for configuration file */
--    if ((home = getenv("IBOD_HOME")) == NULL)
--        home = IBOD_DEFAULT_DIR;
-+    if (argc > 1) {
-+        config_file = argv[1];
-+    } else {
-+        config_file = IBOD_DEFAULT_CONF;
-+    }
-     /* Setup initial attributes */
--    if (setattr(home) == -1) {
-+    if (setattr(config_file) == -1) {
-         closelog();
-         exit(1);
-     }
-@@ -185,10 +189,9 @@
- }
--static int setattr(char *home)
-+static int setattr(char *config_filename)
- {
-     FILE *fd;
--    char config_filename[MAX_STR_LEN];
-     char linebuf[MAX_STR_LEN];
-     char *key, *value;
-     int  val;
-@@ -202,7 +205,6 @@
-     cf.stayup_time = STAYUP_TIME;
-     /* Open config file */
--    sprintf(config_filename, "%s/ibod.cf", home);
-     if ((fd = fopen(config_filename, "r")) == NULL) {
-         syslog(LOG_ERR, "%s: %s\n", config_filename, strerror(errno));
-         return -1;
-@@ -288,7 +290,7 @@
- static void reread(int sig)
- {
--    (void) setattr(home);
-+    (void) setattr(config_file);
-     setinterval();
-diff -Nur ibod-1.4/ibod.h ibod-1.4-conf/ibod.h
---- ibod-1.4/ibod.h    2011-11-11 19:00:45.623454321 +0000
-+++ ibod-1.4-conf/ibod.h       2011-11-11 18:45:39.703353901 +0000
-@@ -11,6 +11,7 @@
- #define STAYUP_TIME           30
- #define IBOD_DEFAULT_DIR      "/etc/isdn"
-+#define IBOD_DEFAULT_CONF     IBOD_DEFAULT_DIR "/ibod.cf"
- #define MAX_STR_LEN           512
- #define ISDN_INFO_DEV         "/dev/isdninfo"
- #define ISDN_CTLR_DEV         "/dev/isdnctrl"