|
|
83eaee |
From ac10bc27090916fe8fcdaf4a9f0e8cc0165f7210 Mon Sep 17 00:00:00 2001
|
|
|
83eaee |
From: Unto Sten <sten.unto@gmail.com>
|
|
|
83eaee |
Date: Sat, 11 May 2019 01:04:16 +0300
|
|
|
83eaee |
Subject: [PATCH] Trivial style fixes
|
|
|
83eaee |
|
|
|
83eaee |
---
|
|
|
83eaee |
libsemanage/src/direct_api.c | 2 +-
|
|
|
83eaee |
libsemanage/src/modules.c | 2 +-
|
|
|
83eaee |
libsemanage/src/seusers_local.c | 2 +-
|
|
|
83eaee |
libsemanage/src/users_local.c | 4 ++--
|
|
|
83eaee |
4 files changed, 5 insertions(+), 5 deletions(-)
|
|
|
83eaee |
|
|
|
83eaee |
diff --git a/libsemanage/src/direct_api.c b/libsemanage/src/direct_api.c
|
|
|
83eaee |
index abc3a4cb..b037890a 100644
|
|
|
83eaee |
--- a/libsemanage/src/direct_api.c
|
|
|
83eaee |
+++ b/libsemanage/src/direct_api.c
|
|
|
83eaee |
@@ -517,7 +517,7 @@ ssize_t bunzip(semanage_handle_t *sh, FILE *f, char **data)
|
|
|
83eaee |
size_t size = 1<<18;
|
|
|
83eaee |
size_t bufsize = size;
|
|
|
83eaee |
int bzerror;
|
|
|
83eaee |
- size_t total=0;
|
|
|
83eaee |
+ size_t total = 0;
|
|
|
83eaee |
char* uncompress = NULL;
|
|
|
83eaee |
char* tmpalloc = NULL;
|
|
|
83eaee |
int ret = -1;
|
|
|
83eaee |
diff --git a/libsemanage/src/modules.c b/libsemanage/src/modules.c
|
|
|
83eaee |
index 62af1018..fa84d33e 100644
|
|
|
83eaee |
--- a/libsemanage/src/modules.c
|
|
|
83eaee |
+++ b/libsemanage/src/modules.c
|
|
|
83eaee |
@@ -1130,7 +1130,7 @@ int semanage_module_install_info(semanage_handle_t *sh,
|
|
|
83eaee |
int semanage_module_remove_key(semanage_handle_t *sh,
|
|
|
83eaee |
const semanage_module_key_t *modkey)
|
|
|
83eaee |
{
|
|
|
83eaee |
- if (sh->funcs->remove_key== NULL) {
|
|
|
83eaee |
+ if (sh->funcs->remove_key == NULL) {
|
|
|
83eaee |
ERR(sh,
|
|
|
83eaee |
"No remove key function defined for this connection type.");
|
|
|
83eaee |
return -1;
|
|
|
83eaee |
diff --git a/libsemanage/src/seusers_local.c b/libsemanage/src/seusers_local.c
|
|
|
83eaee |
index a79e2d3d..3e2761c4 100644
|
|
|
83eaee |
--- a/libsemanage/src/seusers_local.c
|
|
|
83eaee |
+++ b/libsemanage/src/seusers_local.c
|
|
|
83eaee |
@@ -133,7 +133,7 @@ int semanage_seuser_modify_local(semanage_handle_t * handle,
|
|
|
83eaee |
semanage_seuser_t *new = NULL;
|
|
|
83eaee |
|
|
|
83eaee |
if (!sename) {
|
|
|
83eaee |
- errno=EINVAL;
|
|
|
83eaee |
+ errno = EINVAL;
|
|
|
83eaee |
return -1;
|
|
|
83eaee |
}
|
|
|
83eaee |
rc = semanage_seuser_clone(handle, data, &new;;
|
|
|
83eaee |
diff --git a/libsemanage/src/users_local.c b/libsemanage/src/users_local.c
|
|
|
83eaee |
index 7aa43d44..8193476d 100644
|
|
|
83eaee |
--- a/libsemanage/src/users_local.c
|
|
|
83eaee |
+++ b/libsemanage/src/users_local.c
|
|
|
83eaee |
@@ -38,7 +38,7 @@ static int lookup_seuser(semanage_handle_t * handle, const semanage_user_key_t *
|
|
|
83eaee |
semanage_seuser_list_local(handle,
|
|
|
83eaee |
&records,
|
|
|
83eaee |
&count);
|
|
|
83eaee |
- for(i=0; i
|
|
|
83eaee |
+ for(i = 0; i < count; i++) {
|
|
|
83eaee |
sename = semanage_seuser_get_sename(records[i]);
|
|
|
83eaee |
if (strcmp(name, sename) == 0) {
|
|
|
83eaee |
errno = EINVAL;
|
|
|
83eaee |
@@ -47,7 +47,7 @@ static int lookup_seuser(semanage_handle_t * handle, const semanage_user_key_t *
|
|
|
83eaee |
rc = -1;
|
|
|
83eaee |
}
|
|
|
83eaee |
}
|
|
|
83eaee |
- for(i=0; i
|
|
|
83eaee |
+ for(i = 0; i < count; i++)
|
|
|
83eaee |
semanage_seuser_free(records[i]);
|
|
|
83eaee |
free(records);
|
|
|
83eaee |
semanage_user_free(user);
|
|
|
83eaee |
--
|
|
|
83eaee |
2.30.2
|
|
|
83eaee |
|