[Mono-bugs] [Bug 361352] New: Several bugs in ApplicationSettingsBase

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Feb 12 21:40:53 EST 2008


           Summary: Several bugs in ApplicationSettingsBase
           Product: Mono: Class Libraries
           Version: SVN
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Configuration
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: alan.mcgovern at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---

Created an attachment (id=194573)
 --> (https://bugzilla.novell.com/attachment.cgi?id=194573)
A new test for Nunit and some changes

First a few comments on my patch:

+                       if(owner.Site != null)
+                               providerService =

In the app i'm porting owner.Site == null. Putting in this check stops a null
ref from being thrown. Everything appears to work ok with this check.

+                       if (propertyValues == null)
+                               propertyValues = new
+                       propertyValues.Add(new SettingsPropertyValue(setting));

This is the wrong place to put this. I have no doubt in my mind ;) However i'm
not sure how best to handle this. I've noticed that when testing the MS.NET
implementation, the property values are filled in and exist when the class
loads the settings. The current implementation doesn't do this. Adding these
lines allows my application to start up and load/save settings correctly.

Finally, if you run the testcase below, you'll error out with an
InvalidOperationException. In MS.NET, the virtual methods are not called when
instantiating the class and so everything sets up correctly. When you are
setting up the properties internally, you have to call base.Context etc. Or
access the private member directly.

Hope all that makes sense.

Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.

More information about the mono-bugs mailing list