https://bugzilla.novell.com/show_bug.cgi?id=385638


           Summary: Sharing violation on path when saving XDocument
           Product: Mono: Class Libraries
           Version: 1.9.0
          Platform: 32bit
        OS/Version: Windows Vista
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Sys.XML
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]
         QAContact: [email protected]
          Found By: ---


I have an asp.net website. I am using XLinq to edit and save a xml document.
When I try to save an open document in the same filepath I get this error:
System.IO.IOException: Sharing violation on path
C:\workspace\Xp\web\App_Data\data.xml

Steps to reproduce:
Open a xml document with System.Xml.Linq.XDocument.Load()
Save the document with System.Xml.Linq.XDocument.Save() updating the source
file.


Code example:
string dataFile = HttpContext.Current.Request.MapPath("~/App_Data/data.xml");

XDocument xdoc = XDocument.Load(dataFile);
xdoc.Save(HttpContext.Current.Request.MapPath("~/App_Data/data.xml"));

Note:
It works fine with MS Asp.Net Development Server


-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to