• R/O
  • SSH
  • HTTPS

ewatch: Commit


Commit MetaInfo

Revision105 (tree)
Zeit2019-11-10 17:21:03
Autorbananajinn

Log Message

非Windows環境の対応

Ändern Zusammenfassung

Diff

--- trunk/EWatch/EWatch/Watchers/WatchThread.cs (revision 104)
+++ trunk/EWatch/EWatch/Watchers/WatchThread.cs (revision 105)
@@ -74,13 +74,13 @@
7474 private void CreateWatchers()
7575 {
7676 watchers = new List<BaseWatcher>();
77- if (Environment.OSVersion.Platform == PlatformID.Win32NT) {
78- Dictionary<string, List<ActionTable>> eventlogs = config.EventLog;
79- foreach (string name in eventlogs.Keys) {
80- BaseWatcher watcher = new EventLogWatcher(name, eventlogs[name]);
81- watchers.Add(watcher);
82- }
83- }
77+#if _WINDOWS
78+ Dictionary<string, List<ActionTable>> eventlogs = config.EventLog;
79+ foreach (string name in eventlogs.Keys) {
80+ BaseWatcher watcher = new EventLogWatcher(name, eventlogs[name]);
81+ watchers.Add(watcher);
82+ }
83+#endif
8484 Dictionary<string,List<ActionTable>> files = config.File;
8585 foreach(string path in files.Keys){
8686 var fileAndEncoding = FileAndEncoding.Parse(path);
Show on old repository browser