summaryrefslogtreecommitdiff
path: root/os/log.c
diff options
context:
space:
mode:
authorAdam Jackson <ajax@redhat.com>2008-05-14 15:53:11 -0400
committerAdam Jackson <ajax@redhat.com>2008-05-14 15:53:11 -0400
commit2efe1abb6fc786a4f86464978ae0d23fc7347a98 (patch)
treea06dd6b79df15f75c67f072af58e75a4728d9f6d /os/log.c
parent6c27b911222cdee9a057de0be7e8b2eff8b1ff2a (diff)
Remove global argc/argv variables.
Was only used in the logging code anymore, and uselessly so there.
Diffstat (limited to 'os/log.c')
-rw-r--r--os/log.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/os/log.c b/os/log.c
index 8c579fd0c..2a59a00b3 100644
--- a/os/log.c
+++ b/os/log.c
@@ -410,9 +410,7 @@ AbortServer(void)
exit (1);
}
-#ifndef AUDIT_PREFIX
-#define AUDIT_PREFIX "AUDIT: %s: %ld %s: "
-#endif
+#define AUDIT_PREFIX "AUDIT: %s: %ld: "
#ifndef AUDIT_TIMEOUT
#define AUDIT_TIMEOUT ((CARD32)(120 * 1000)) /* 2 mn */
#endif
@@ -444,15 +442,11 @@ AuditPrefix(void)
autime = ctime(&tm);
if ((s = strchr(autime, '\n')))
*s = '\0';
- if ((s = strrchr(argvGlobal[0], '/')))
- s++;
- else
- s = argvGlobal[0];
- len = strlen(AUDIT_PREFIX) + strlen(autime) + 10 + strlen(s) + 1;
+ len = strlen(AUDIT_PREFIX) + strlen(autime) + 10 + 1;
tmpBuf = malloc(len);
if (!tmpBuf)
return NULL;
- snprintf(tmpBuf, len, AUDIT_PREFIX, autime, (unsigned long)getpid(), s);
+ snprintf(tmpBuf, len, AUDIT_PREFIX, autime, (unsigned long)getpid());
return tmpBuf;
}