Use PROGNAME
This commit is contained in:
parent
2971d7edaf
commit
65d9ecb0a1
|
@ -23,6 +23,8 @@
|
||||||
#include "../src/window.h"
|
#include "../src/window.h"
|
||||||
#include "Panel/applet.h"
|
#include "Panel/applet.h"
|
||||||
|
|
||||||
|
#define PROGNAME "applets2"
|
||||||
|
|
||||||
|
|
||||||
/* private */
|
/* private */
|
||||||
/* prototypes */
|
/* prototypes */
|
||||||
|
@ -130,14 +132,13 @@ static gboolean _applets2(gpointer data)
|
||||||
static char const * _applets2_helper_config_get(Panel * panel,
|
static char const * _applets2_helper_config_get(Panel * panel,
|
||||||
char const * section, char const * variable)
|
char const * section, char const * variable)
|
||||||
{
|
{
|
||||||
printf("%s: config_get(\"%s\", \"%s\")\n", "applets2", section,
|
printf("%s: config_get(\"%s\", \"%s\")\n", PROGNAME, section, variable);
|
||||||
variable);
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int _applets2_helper_error(Panel * panel, char const * message, int ret)
|
static int _applets2_helper_error(Panel * panel, char const * message, int ret)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "%s: %s\n", "applets2", message);
|
fprintf(stderr, "%s: %s\n", PROGNAME, message);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -145,7 +146,7 @@ static int _applets2_helper_error(Panel * panel, char const * message, int ret)
|
||||||
/* dlerror */
|
/* dlerror */
|
||||||
static int _dlerror(char const * message, int ret)
|
static int _dlerror(char const * message, int ret)
|
||||||
{
|
{
|
||||||
fputs("applets2: ", stderr);
|
fputs(PROGNAME ": ", stderr);
|
||||||
fprintf(stderr, "%s: %s\n", message, dlerror());
|
fprintf(stderr, "%s: %s\n", message, dlerror());
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
@ -154,7 +155,7 @@ static int _dlerror(char const * message, int ret)
|
||||||
/* error */
|
/* error */
|
||||||
static int _error(char const * message, char const * error, int ret)
|
static int _error(char const * message, char const * error, int ret)
|
||||||
{
|
{
|
||||||
fputs("applets2: ", stderr);
|
fputs(PROGNAME ": ", stderr);
|
||||||
fprintf(stderr, "%s: %s\n", message, error);
|
fprintf(stderr, "%s: %s\n", message, error);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
@ -163,7 +164,7 @@ static int _error(char const * message, char const * error, int ret)
|
||||||
/* perror */
|
/* perror */
|
||||||
static int _perror(char const * message, int ret)
|
static int _perror(char const * message, int ret)
|
||||||
{
|
{
|
||||||
fputs("applets2: ", stderr);
|
fputs(PROGNAME ": ", stderr);
|
||||||
perror(message);
|
perror(message);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user