File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -127,6 +127,7 @@ static void ConfigureLogging(Arguments arguments)
127
127
writeActions . Add ( Console . WriteLine ) ;
128
128
}
129
129
130
+ Exception exception = null ;
130
131
if ( arguments . LogFilePath != null && arguments . LogFilePath != "console" )
131
132
{
132
133
try
@@ -148,14 +149,17 @@ static void ConfigureLogging(Arguments arguments)
148
149
}
149
150
catch ( Exception ex )
150
151
{
151
- Logger . WriteError ( String . Format ( "Failed to configure logging for '{0}': {1}" , arguments . LogFilePath , ex . Message ) ) ;
152
+ exception = ex ;
152
153
}
153
154
}
154
155
155
156
Logger . SetLoggers (
156
157
s => writeActions . ForEach ( a => a ( s ) ) ,
157
158
s => writeActions . ForEach ( a => a ( s ) ) ,
158
159
s => writeActions . ForEach ( a => a ( s ) ) ) ;
160
+
161
+ if ( exception != null )
162
+ Logger . WriteError ( string . Format ( "Failed to configure logging for '{0}': {1}" , arguments . LogFilePath , exception . Message ) ) ;
159
163
}
160
164
161
165
static void WriteLogEntry ( Arguments arguments , string s )
You can’t perform that action at this time.
0 commit comments