aboutsummaryrefslogtreecommitdiff
path: root/src/acl.c
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2016-02-23 11:36:33 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2016-02-23 12:25:47 +0200
commit6e73a7b0822d1fd506c75a662070f447bba94afb (patch)
treee121c440aff73316cb43ec05295e2c32492bf5dc /src/acl.c
parent584266f8215d913ce0c226f63da51c77d1074f09 (diff)
downloadpies-6e73a7b0822d1fd506c75a662070f447bba94afb.tar.gz
pies-6e73a7b0822d1fd506c75a662070f447bba94afb.tar.bz2
Improve logging
* po/POTFILES.in: Add missing source files. * grecs: Upgrade. * src/diag.c (pies_diag_printer): New function. (logfuncall): New function. * src/pies.h: Add new prototypes. * src/pies.c (main): Initialize grecs_print_diag_fun * src/acl.c: Uniformly use double-quotes in messages. Use logfuncall where applicable. * src/comp.c: Likewise. * src/ctl.c: Likewise. * src/inetd-bi.c: Likewise. * src/inetd.c: Likewise. * src/limits.c: Likewise. * src/piesctl.c: Likewise. * src/progman.c: Likewise. * src/socket.c: Likewise. * src/sysvinit.c: Likewise.
Diffstat (limited to 'src/acl.c')
-rw-r--r--src/acl.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/acl.c b/src/acl.c
index 53e5dd8..7b834c9 100644
--- a/src/acl.c
+++ b/src/acl.c
@@ -177,7 +177,7 @@ _parse_sockaddr (struct acl_entry *entry, const grecs_value_t *value)
if (len >= sizeof (s_un->sun_path))
{
grecs_error (&entry->locus, 0,
- _("socket name too long: `%s'"), string);
+ _("socket name too long: %s"), string);
return 1;
}
sptr = create_acl_sockaddr (AF_UNIX, sizeof (s_un));
@@ -200,7 +200,7 @@ _parse_sockaddr (struct acl_entry *entry, const grecs_value_t *value)
if (!hp)
{
grecs_error (&entry->locus, 0,
- _("cannot resolve host name: `%s'"), string);
+ _("cannot resolve host name: %s"), string);
if (p)
*p = '/';
return 1;
@@ -237,14 +237,14 @@ _parse_sockaddr (struct acl_entry *entry, const grecs_value_t *value)
if (inet_aton (p, &addr) == 0)
{
grecs_error (&entry->locus, 0,
- _("invalid netmask: `%s'"), p);
+ _("invalid netmask: %s"), p);
return 1;
}
sptr->netmask = addr.s_addr;
}
else
{
- grecs_error (&entry->locus, 0, _("invalid netmask: `%s'"), p);
+ grecs_error (&entry->locus, 0, _("invalid netmask: %s"), p);
return 1;
}
}
@@ -281,12 +281,12 @@ _parse_from (struct acl_entry *entry, size_t argc, grecs_value_t **argv)
return 0;
else if (argv[0]->type == GRECS_TYPE_LIST)
{
- grecs_error (&entry->locus, 0, _("expected `from', but found list"));
+ grecs_error (&entry->locus, 0, _("expected \"from\", but found list"));
return 1;
}
else if (strcmp (argv[0]->v.string, "from"))
{
- grecs_error (&entry->locus, 0, _("expected `from', but found `%s'"),
+ grecs_error (&entry->locus, 0, _("expected \"from\", but found \"%s\""),
argv[0]->v.string);
return 1;
}
@@ -296,7 +296,7 @@ _parse_from (struct acl_entry *entry, size_t argc, grecs_value_t **argv)
if (argc == 0)
{
grecs_error (&entry->locus, 0,
- _("unexpected end of statement after `from'"));
+ _("unexpected end of statement after \"from\""));
return 1;
}
@@ -321,7 +321,7 @@ _parse_from (struct acl_entry *entry, size_t argc, grecs_value_t **argv)
if (argc - 1)
{
- grecs_warning (&entry->locus, 0, _("junk after `from' list"));
+ grecs_warning (&entry->locus, 0, _("junk after from-list"));
return 1;
}
return 0;
@@ -354,8 +354,8 @@ _parse_sub_acl (struct acl_entry *entry, size_t argc, grecs_value_t **argv)
if (!entry->acl)
{
- grecs_error (&entry->locus, 0, _("ACL not defined: `%s'"),
- argv[0]->v.string);
+ grecs_error (&entry->locus, 0, _("ACL not defined: %s"),
+ argv[0]->v.string);
return 1;
}
argc--;
@@ -432,7 +432,7 @@ parse_acl_line (grecs_locus_t *locus, int allow, pies_acl_t acl,
case GRECS_TYPE_STRING:
if (_parse_token (entry, value))
{
- grecs_error (&entry->locus, 0, _("unknown word `%s'"),
+ grecs_error (&entry->locus, 0, _("unknown word: %s"),
value->v.string);
return 1;
}

Return to:

Send suggestions and report system problems to the System administrator.