Use PROGNAME_WIFIBROWSER for wifibrowser(1)
This commit is contained in:
parent
3a145c35c6
commit
6faafd4517
|
@ -29,8 +29,8 @@
|
||||||
#define _(string) gettext(string)
|
#define _(string) gettext(string)
|
||||||
|
|
||||||
/* constants */
|
/* constants */
|
||||||
#ifndef PROGNAME
|
#ifndef PROGNAME_WIFIBROWSER
|
||||||
# define PROGNAME "wifibrowser"
|
# define PROGNAME_WIFIBROWSER "wifibrowser"
|
||||||
#endif
|
#endif
|
||||||
#ifndef PREFIX
|
#ifndef PREFIX
|
||||||
# define PREFIX "/usr/local"
|
# define PREFIX "/usr/local"
|
||||||
|
@ -100,14 +100,14 @@ static int _wifibrowser(char const * configfile, char const * interface)
|
||||||
{
|
{
|
||||||
if(configfile != NULL
|
if(configfile != NULL
|
||||||
&& config_load(panel.config, configfile) != 0)
|
&& config_load(panel.config, configfile) != 0)
|
||||||
error_print(PROGNAME);
|
error_print(PROGNAME_WIFIBROWSER);
|
||||||
if(interface != NULL
|
if(interface != NULL
|
||||||
&& config_set(panel.config, "wpa_supplicant",
|
&& config_set(panel.config, "wpa_supplicant",
|
||||||
"interface", interface) != 0)
|
"interface", interface) != 0)
|
||||||
error_print(PROGNAME);
|
error_print(PROGNAME_WIFIBROWSER);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
error_print(PROGNAME);
|
error_print(PROGNAME_WIFIBROWSER);
|
||||||
/* FIXME load the configuration */
|
/* FIXME load the configuration */
|
||||||
memset(&helper, 0, sizeof(helper));
|
memset(&helper, 0, sizeof(helper));
|
||||||
helper.panel = &panel;
|
helper.panel = &panel;
|
||||||
|
@ -190,7 +190,7 @@ static int _error(Panel * panel, char const * message, int ret)
|
||||||
{
|
{
|
||||||
(void) panel;
|
(void) panel;
|
||||||
|
|
||||||
fputs(PROGNAME ": ", stderr);
|
fputs(PROGNAME_WIFIBROWSER ": ", stderr);
|
||||||
perror(message);
|
perror(message);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
@ -201,7 +201,7 @@ static int _usage(void)
|
||||||
{
|
{
|
||||||
fprintf(stderr, _("Usage: %s [-c filename][-i interface]\n"
|
fprintf(stderr, _("Usage: %s [-c filename][-i interface]\n"
|
||||||
" -c Path to a configuration file\n"
|
" -c Path to a configuration file\n"
|
||||||
" -i Network interface to connect to\n"), PROGNAME);
|
" -i Network interface to connect to\n"), PROGNAME_WIFIBROWSER);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user