summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 5ff74d5)
raw | patch | inline | side by side (parent: 5ff74d5)
author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 30 Jun 2017 14:37:25 +0000 (16:37 +0200) | ||
committer | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 30 Jun 2017 14:37:25 +0000 (16:37 +0200) |
src/exec.c | patch | blob | history |
diff --git a/src/exec.c b/src/exec.c
index 80515d93d3ec4861d3cd69de7260bbd4e60ba8d3..3d12a2de2037b83c4cc4a5e8e3b392cfb62c43ee 100644 (file)
--- a/src/exec.c
+++ b/src/exec.c
/* The group configured in the configfile is set as effective group, because
* this way the forked process can (re-)gain the user's primary group. */
egid = -1;
- if (NULL != pl->group) {
- if ('\0' != *pl->group) {
+ if (pl->group != NULL) {
+ if (*pl->group != '\0') {
struct group *gr_ptr = NULL;
struct group gr;
status = getgrnam_r(pl->group, &gr, nambuf, sizeof(nambuf), &gr_ptr);
- if (0 != status) {
+ if (status != 0) {
ERROR("exec plugin: Failed to get group information "
"for group ``%s'': %s",
pl->group, sstrerror(status, errbuf, sizeof(errbuf)));
goto failed;
}
- if (NULL == gr_ptr) {
+ if (gr_ptr == NULL) {
ERROR("exec plugin: No such group: `%s'", pl->group);
goto failed;
}