audit/audisp-restore-fix.patch
Cropi ff70a3750e c9s bugfix
Disable ProtectKernelModules=true in service file
  Resolves: RHEL-59570
af_unix plugin: restore original behavior in binary mode
  Resolves: RHEL-59585
Support image mode
  Resolves: RHEL-69033
Resolve ordering cycle when using remote logging
  Resolves: RHEL-11252
Filter syscalls to ensure architecture-specific availability
  Resolves: RHEL-70455
2025-01-15 10:03:09 +01:00

39 lines
1.0 KiB
Diff

diff --git a/audisp/plugins/af_unix/audisp-af_unix.c b/audisp/plugins/af_unix/audisp-af_unix.c
index d85f15f8a..578533f52 100644
--- a/audisp/plugins/af_unix/audisp-af_unix.c
+++ b/audisp/plugins/af_unix/audisp-af_unix.c
@@ -132,7 +132,7 @@ int setup_socket(int argc, char *argv[])
if (errno) {
syslog(LOG_ERR,
"Error converting %s (%s)",
- arg[i], strerror(errno));
+ argv[i], strerror(errno));
mode = 0;
}
} else if (strchr(arg, '/') != NULL) {
@@ -265,16 +265,15 @@ void read_audit_record(int ifd)
do {
rc = writev(conn, vec, 2);
} while (rc < 0 && errno == EINTR);
- }
-
- if (rc < 0 && errno == EPIPE) {
- close(conn);
- conn = -1;
- client = 0;
- audit_fgets_clear();
- }
- if (rc >= 0 && rc != len) {
+ if (rc < 0 && errno == EPIPE) {
+ close(conn);
+ conn = -1;
+ client = 0;
+ audit_fgets_clear();
+ }
+ //if (rc >= 0 && rc != len) {
// what to do with leftovers?
+ //}
}
}
#endif