Commit 84ebd48
committed
Handle Exception.ToString() failures in template compilation
Wrap Exception.ToString() in a try-catch block to handle potential failures. If an exception occurs, output a fallback message with details about the original exception and the error encountered.1 parent 1b6a42d commit 84ebd48
File tree
1 file changed
+11
-1
lines changed- src/Serilog.Expressions/Templates/Compilation
1 file changed
+11
-1
lines changedLines changed: 11 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
40 | 50 | | |
41 | 51 | | |
42 | 52 | | |
| |||
0 commit comments