summaryrefslogtreecommitdiffstats
path: root/support/nfs/xlog.c
diff options
context:
space:
mode:
Diffstat (limited to 'support/nfs/xlog.c')
-rw-r--r--support/nfs/xlog.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/support/nfs/xlog.c b/support/nfs/xlog.c
index 6820346..83d07e1 100644
--- a/support/nfs/xlog.c
+++ b/support/nfs/xlog.c
@@ -38,6 +38,8 @@ static int logmask = 0; /* What will be logged */
static char log_name[256]; /* name of this program */
static int log_pid = -1; /* PID of this program */
+int export_errno = 0;
+
static void xlog_toggle(int sig);
static struct xlog_debugfac debugnames[] = {
{ "general", D_GENERAL, },
@@ -190,6 +192,9 @@ xlog(int kind, const char* fmt, ...)
{
va_list args;
+ if (kind & (L_ERROR|D_GENERAL))
+ export_errno = 1;
+
va_start(args, fmt);
xlog_backend(kind, fmt, args);
va_end(args);