diff options
author | Lluis Sanchez <lluis@xamarin.com> | 2014-05-23 19:34:08 +0400 |
---|---|---|
committer | Lluis Sanchez <lluis@xamarin.com> | 2014-05-23 21:25:03 +0400 |
commit | aa6365d91f1eb2ab4872996d2c44b539f5416a1e (patch) | |
tree | fc6c667ec2a5d9fdc3b4397aa4492b30219e7f28 | |
parent | d1f96e1db0f8b18de2a35cd7a4a3fbdede403d01 (diff) |
Fix package creation issue
Reset the xml doc so that it is not reused when saving. We want a brand
new document.
-rw-r--r-- | Mono.Addins/Mono.Addins.Database/AddinDatabase.cs | 5 | ||||
-rw-r--r-- | Mono.Addins/Mono.Addins.Description/AddinDescription.cs | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/Mono.Addins/Mono.Addins.Database/AddinDatabase.cs b/Mono.Addins/Mono.Addins.Database/AddinDatabase.cs index f7357a0..fd20506 100644 --- a/Mono.Addins/Mono.Addins.Database/AddinDatabase.cs +++ b/Mono.Addins/Mono.Addins.Database/AddinDatabase.cs @@ -1443,8 +1443,11 @@ namespace Mono.Addins.Database if (einfo != null) einfo.AddEventHandler (AppDomain.CurrentDomain, resolver); AddinDescription desc = scanner.ScanSingleFile (progressStatus, file, sr); - if (desc != null) + if (desc != null) { + // Reset the xml doc so that it is not reused when saving. We want a brand new document + desc.ResetXmlDoc (); desc.Save (outFile); + } } finally { AppDomain.CurrentDomain.AssemblyResolve -= resolver; diff --git a/Mono.Addins/Mono.Addins.Description/AddinDescription.cs b/Mono.Addins/Mono.Addins.Description/AddinDescription.cs index 00eaaf2..6b3059b 100644 --- a/Mono.Addins/Mono.Addins.Description/AddinDescription.cs +++ b/Mono.Addins/Mono.Addins.Description/AddinDescription.cs @@ -613,6 +613,11 @@ namespace Mono.Addins.Description return null; } } + + internal void ResetXmlDoc () + { + configDoc = null; + } /// <summary> /// Gets or sets file where this description is stored |