summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--source3/utils/eventlogadm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/utils/eventlogadm.c b/source3/utils/eventlogadm.c
index 8d8fa4a4d74..b54353613cb 100644
--- a/source3/utils/eventlogadm.c
+++ b/source3/utils/eventlogadm.c
@@ -121,7 +121,7 @@ static bool eventlog_add_source( const char *eventlog, const char *sourcename,
goto done;
}
- relpath = strchr(evtlogpath, '\\');
+ relpath = evtlogpath + sizeof(KEY_EVENTLOG);
hive_name = talloc_strndup(ctx, evtlogpath, relpath - evtlogpath);
if (!hive_name) {
d_printf("Out of memory\n");