Remove the hard-coded 'ath0' strings and use ATH_DEFAULT.

Remove the duplicate ATH_DEFAULT fields.  The build bits should be including
../Makefile.inc as appropriate.
This commit is contained in:
Adrian Chadd 2016-02-07 04:28:03 +00:00
parent 062b0cc0e6
commit 65f41e586b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=295363
6 changed files with 5 additions and 13 deletions

View File

@ -89,7 +89,7 @@ main(int argc, char *argv[])
ifname = getenv("ATH");
if (ifname == NULL)
ifname = "ath0";
ifname = ATH_DEFAULT;
wf = athaggrstats_new(ifname, getfmt("default"));
while ((c = getopt(argc, argv, "bi:lo:z")) != -1) {
switch (c) {

View File

@ -31,7 +31,7 @@
/*
* athdebug [-i interface] flags
* (default interface is ath0).
* (default interface is wlan0).
*/
#include <sys/param.h>
@ -156,7 +156,7 @@ main(int argc, char *argv[])
ifname = getenv("ATH");
if (ifname == NULL)
ifname = "ath0";
ifname = ATH_DEFAULT;
progname = argv[0];
if (argc > 1) {
if (strcmp(argv[1], "-i") == 0) {

View File

@ -30,10 +30,6 @@
#include "ah.h"
#include "ah_internal.h"
#ifndef ATH_DEFAULT
#define ATH_DEFAULT "ath0"
#endif
#include <getopt.h>
#include <errno.h>
#include <err.h>

View File

@ -310,7 +310,7 @@ main(int argc, char *argv[])
ifname = getenv("ATH");
if (ifname == NULL)
ifname = "ath0";
ifname = ATH_DEFAULT;
while ((c = getopt(argc, argv, "ahi:m:s:")) != -1) {
switch (c) {

View File

@ -30,10 +30,6 @@
#include "ah.h"
#include "ah_internal.h"
#ifndef ATH_DEFAULT
#define ATH_DEFAULT "ath0"
#endif
#include <getopt.h>
#include <errno.h>
#include <err.h>

View File

@ -94,7 +94,7 @@ main(int argc, char *argv[])
ifname = getenv("ATH");
if (ifname == NULL)
ifname = "ath0";
ifname = ATH_DEFAULT;
wf = athstats_new(ifname, getfmt("default"));
while ((c = getopt(argc, argv, "bi:lo:z")) != -1) {
switch (c) {