Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Currently NSObject throws NullReferenceException on first call to observer if callback provided by user is null.
We should check observer parameter in NSObject.AddObserver method. Probably throw argument exception if is observer is null is a good solution.
I have checked this issue with the following build from master:
I observed that this issue has been fixed in master build, now NSObject throws System.ArgumentNullException on first call to observer if callback provided by user is null and this is expected behavior.
However this issue doesn't seems fixed in Cycle 7 build:
Here now NSObject throws System.NullReferenceException
So this issue doesn't fixed in cycle 7, hence I am reopening this issue.
Environment Info: https://gist.github.com/Rajneesh360Logica/c0d70b16f58f88f708631e145e426ae9
Moving target milestone for this bug for C8 since it's not a regression, it was not filed by a customer and it was filed late in the cycle.
I have checked this issue with latest Master build and observed that this issue is working fine.
I will Verify this issue with C8 build.
Xamarin Studio Enterprise 6.1 (build 4412)
Mono 4.5.2 (master/79451d2) (64-bit)
Xamarin.Profiler : 0.32.99
Xcode 7.2 (9548)
Xamarin.iOS: 184.108.40.2067 (Xamarin Enterprise)
Xamarin.Android : 220.127.116.118 (Xamarin Enterprise)
Mac OS X 10.10.5
As per comment #4 marking this issue Verified fixed.