diff options
| author | jpbruyere <jp.bruyere@hotmail.com> | 2016-08-02 00:04:28 +0200 |
|---|---|---|
| committer | jpbruyere <jp.bruyere@hotmail.com> | 2016-08-02 00:04:28 +0200 |
| commit | 64cd2506f789813ddea2159c1ac658f16e09f4bb (patch) | |
| tree | 0fb696e120dc980a278966b857bca5f3f02a52d3 /src | |
| parent | da1e73a01fb296122de7a7d9351f67232355b817 (diff) | |
Show xml file path for exceptions during loading.
modifié : src/Interface.cs
Diffstat (limited to 'src')
| -rw-r--r-- | src/Interface.cs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/Interface.cs b/src/Interface.cs index 07797a10..607044d9 100644 --- a/src/Interface.cs +++ b/src/Interface.cs @@ -219,8 +219,12 @@ namespace Crow Interface.XmlLoaderCount ++; CurrentGOMLPath = path; GraphicObject tmp = null; - using (Stream stream = GetStreamFromPath (path)) { - tmp = Load(stream, GetTopContainerOfXMLStream(stream), hostClass); + try { + using (Stream stream = GetStreamFromPath (path)) { + tmp = Load(stream, GetTopContainerOfXMLStream(stream), hostClass); + } + } catch (Exception ex) { + throw new Exception ("Error loading <" + CurrentGOMLPath + ">:", ex); } Interface.XmlLoaderCount --; |