From f93842608424e642687a97c836fea7c35df570d7 Mon Sep 17 00:00:00 2001 From: Doug Torrance Date: Mon, 28 Jul 2014 22:50:59 -0500 Subject: [PATCH] wmifinfo: bump to version 0.7. --- wmifinfo/Changelog | 8 +++++++- wmifinfo/Makefile | 7 +++++-- wmifinfo/README | 3 ++- wmifinfo/nwn.c | 2 ++ wmifinfo/wmifinfo.c | 50 +++++++++++++++++++++++++++++++++++---------- wmifinfo/xutils.c | 5 +++-- 6 files changed, 58 insertions(+), 17 deletions(-) diff --git a/wmifinfo/Changelog b/wmifinfo/Changelog index 23710b4..4688faf 100644 --- a/wmifinfo/Changelog +++ b/wmifinfo/Changelog @@ -32,9 +32,15 @@ 0.06 Added openBSD support - - Peter Stromberg supplied a patch for + - Peter Stromberg supplied a patch for OpenBSD support. I have not tried this myself since I don't have access to this OS. I will probably split the code into several OS-dependend modules later, for now the main .c file has some #ifdefs for linux and OpenBSD. + +0.07 New feature + + - On request of Jesper Anderson , wmifinfo + now always switches to new interfaces when they become available; + handy for new established PPP links or inserted PCMCIA cards diff --git a/wmifinfo/Makefile b/wmifinfo/Makefile index 009e7f5..ddb2121 100644 --- a/wmifinfo/Makefile +++ b/wmifinfo/Makefile @@ -9,7 +9,7 @@ ENABLE_NWN_SUPPORT=n # Nothing to configure under here NAME=wmifinfo -VERSION=0.06 +VERSION=0.07 CC = gcc LD = gcc @@ -40,4 +40,7 @@ install: cp $(BIN) $(BINDIR) dist: clean - cd .. && tar -zcvf dist/wmifinfo-$(VERSION).tgz wmifinfo-$(VERSION)/ + rm -rf /tmp/wmifinfo-$(VERSION) + cd .. && cp -a wmifinfo /tmp/wmifinfo-$(VERSION) + cd /tmp && tar --exclude CVS -zcvf wmifinfo-$(VERSION).tgz wmifinfo-$(VERSION)/ + diff --git a/wmifinfo/README b/wmifinfo/README index e3543f9..1329b77 100644 --- a/wmifinfo/README +++ b/wmifinfo/README @@ -90,6 +90,7 @@ COPYRIGHT You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + \ No newline at end of file diff --git a/wmifinfo/nwn.c b/wmifinfo/nwn.c index 4278127..6c23c64 100644 --- a/wmifinfo/nwn.c +++ b/wmifinfo/nwn.c @@ -4,6 +4,8 @@ * cards. Since there seems to be no official range for the 'Quality' value I assume * it's between 0 and 15, and multiply by 4 to get the range 0-63... * + * $Id: nwn.c,v 1.2 2002/09/15 14:31:41 ico Exp $ + * */ #ifdef ENABLE_NWN_SUPPORT diff --git a/wmifinfo/wmifinfo.c b/wmifinfo/wmifinfo.c index 9c6b8a7..f390123 100644 --- a/wmifinfo/wmifinfo.c +++ b/wmifinfo/wmifinfo.c @@ -1,4 +1,7 @@ - +/* + * $Id: wmifinfo.c,v 1.3 2004/03/03 18:29:50 ico Exp $ + */ + #include #include #ifdef linux @@ -630,10 +633,6 @@ void addifname(char *name) strcpy(ifname[ifaces], name); - if(strcasecmp(name, startif) == 0) { - ifno = ifaces; - startif[0] = 0; - } ifaces++; @@ -647,14 +646,24 @@ void addifname(char *name) void getifnames(void) { + char pifname[MAXIFS][16]; + int pifaces; + int i,j; + int isnew; + + /* + * Copy list of interface names and clean the old list + */ + + for(i=0; i