[hyena] Log: honor message parameter in Error(msg,ex)
- From: Andrés Aragoneses <aaragoneses src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [hyena] Log: honor message parameter in Error(msg,ex)
- Date: Sat, 2 Aug 2014 11:50:04 +0000 (UTC)
commit d7ff4ca3d1cdbd2f5e369c72d8ddbf7b74828f20
Author: Andrés G. Aragoneses <knocte gmail com>
Date: Sat Aug 2 13:49:55 2014 +0200
Log: honor message parameter in Error(msg,ex)
After the refactoring to allow Error(ex) and Warning(ex)
overloads, this detail was overlooked, as 'severe' bool
param is no longer determined by the lack of message.
Hyena/Hyena/Log.cs | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/Hyena/Hyena/Log.cs b/Hyena/Hyena/Log.cs
index 75a6c51..566116e 100644
--- a/Hyena/Hyena/Log.cs
+++ b/Hyena/Hyena/Log.cs
@@ -454,10 +454,11 @@ namespace Hyena
}
}
+ var msg = message ?? "Caught an exception";
if (!severe) {
- Log.Warning (message, builder.ToString (), false);
+ Log.Warning (msg, builder.ToString (), false);
} else {
- Log.Error ("Caught an exception", builder.ToString (), false);
+ Log.Error (msg, builder.ToString (), false);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]