File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -120,10 +120,12 @@ private enum WTS_INFO_CLASS
120120
121121 public static void log ( string msg )
122122 {
123+ #if ( DEBUG )
123124 string strAppPath = Path . Combine ( Path . GetDirectoryName ( System . Reflection . Assembly . GetEntryAssembly ( ) . Location ) , "lt_daemon.log" ) ;
124125 FileStream fs = File . Open ( strAppPath , FileMode . Append ) ;
125126 fs . Write ( System . Text . UTF8Encoding . UTF8 . GetBytes ( msg + "\r \n " ) ) ;
126127 fs . Close ( ) ;
128+ #endif
127129 }
128130 /// <devdoc>
129131 /// Gets the user token from the currently active session. Application must be running within the context of the LocalSystem Account.
Original file line number Diff line number Diff line change 1- @ echo off
2- @ rem Intended to run from the same directory (e.g. bin); build should copy to bin.
3- sc create " LenovoFanDaemon" binpath= " %~dp0 lf_daemon.exe LenovoFan.exe" displayname= " LenovoFanDaemon"
4- sc start " LenovoFanDaemon"
1+ @ echo off
2+ @ rem Intended to run from the same directory (e.g. bin); build should copy to bin.
3+ sc create " LenovoFanDaemon" binpath= " %~dp0 lf_daemon.exe LenovoFan.exe" displayname= " LenovoFanDaemon" start=auto
4+ sc start " LenovoFanDaemon"
You can’t perform that action at this time.
0 commit comments