aboutsummaryrefslogtreecommitdiff
path: root/src/sg.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/sg.c')
-rw-r--r--src/sg.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/sg.c b/src/sg.c
index 2fc0a9b..160851c 100644
--- a/src/sg.c
+++ b/src/sg.c
@@ -17,14 +17,9 @@
#include "eclat.h"
#include <arpa/inet.h>
#include <netdb.h>
+#include "sg.h"
-#define GROUP_ID 0
-#define GROUP_NAME 1
-
-static struct {
- char *resid;
- char *map;
-} rt[] = {
+struct groupkw groupkw[] = {
{ "GroupId", MAP_GROUPID },
{ "GroupName", MAP_GROUPNAME }
};
@@ -174,7 +169,7 @@ flush_rule()
grecs_asprintf(&bufptr, &bufsize,
"IpPermissions.%d.Groups.%d.%s",
rule_n, i,
- rt[a->type].resid);
+ groupkw[a->type].resid);
eclat_query_add_param(query, bufptr, a->str);
if (a->usr) {
grecs_asprintf(&bufptr, &bufsize,

Return to:

Send suggestions and report system problems to the System administrator.