Commit f9f867b2 authored by Leigh B. Stoller's avatar Leigh B. Stoller
Browse files

Add a LogAbort routine to stop a logging session.

parent 417722a3
......@@ -13,7 +13,7 @@ use Exporter;
@EXPORT =
qw ( AuditStart AuditEnd AuditAbort AuditFork AuditSetARGV AuditGetARGV
AddAuditInfo
LogStart LogEnd
LogStart LogEnd LogAbort
LIBAUDIT_NODAEMON LIBAUDIT_DAEMON LIBAUDIT_LOGONLY
LIBAUDIT_NODELETE LIBAUDIT_FANCY LIBAUDIT_LOGTBOPS
);
......@@ -231,6 +231,11 @@ sub LogEnd(;$)
return AuditEnd($status);
}
sub LogAbort()
{
return AuditAbort();
}
#
# Finish an Audit.
#
......@@ -271,6 +276,11 @@ sub AuditAbort()
if ($auditing) {
$auditing = 0;
if (!$daemon && $PERL_VERSION >= 5.008) {
eval("open(STDOUT, \">&\", \$libaudit::SAVE_STDOUT); ".
"open(STDERR, \">&\", \$libaudit::SAVE_STDERR);");
}
if (defined($logfile)) {
#
# This should be okay; the process will keep writing to it,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment