Skip to content
This repository was archived by the owner on May 11, 2024. It is now read-only.

Commit e511f0a

Browse files
committed
fix: product version formatted into event log type
1 parent 826879b commit e511f0a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

SMLogging.Setup.CustomActions/CustomActions.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ private static void RegisterRequestLogging(string path, Session session)
109109
new XAttribute("name", "Default")),
110110
new XElement("add",
111111
new XAttribute("name", EventLogListenerName),
112-
new XAttribute("type", EventLogTraceListenerType),
112+
new XAttribute("type", String.Format(EventLogTraceListenerTypeFormat, data["ProductVersion"])),
113113
new XAttribute("initializeData", EventLogSourceName)))));
114114
}
115115

@@ -229,7 +229,7 @@ private static void RegisterErrorLogging(string path, Session session)
229229
new XAttribute("name", "Default")),
230230
new XElement("add",
231231
new XAttribute("name", EventLogListenerName),
232-
new XAttribute("type", EventLogTraceListenerType),
232+
new XAttribute("type", String.Format(EventLogTraceListenerTypeFormat, data["ProductVersion"])),
233233
new XAttribute("initializeData", EventLogSourceName)))));
234234
}
235235

@@ -349,7 +349,7 @@ private static void SetupDirectory(string path)
349349
private const string ErrorLoggingFailSourceName = "System.ServiceModel.ErrorLogging.Fail";
350350
private const string ErrorLoggingFailSourceSwitchValue = "Error";
351351
private const string EventLogListenerName = "EventLog";
352-
private const string EventLogTraceListenerType = "SMLogging.WindowsEventLogTraceListener, SMLogging, Version={0}.0, Culture=neutral, PublicKeyToken=ddc81ec55fc35caf";
352+
private const string EventLogTraceListenerTypeFormat = "SMLogging.WindowsEventLogTraceListener, SMLogging, Version={0}.0, Culture=neutral, PublicKeyToken=ddc81ec55fc35caf";
353353
private const string EventLogSourceName = "SMLogging";
354354

355355
#endregion

0 commit comments

Comments
 (0)