Bug 15740 - ConfigurationFile return null pointer when called from unmanaged code
Summary: ConfigurationFile return null pointer when called from unmanaged code
Status: RESOLVED ANSWERED
Alias: None
Product: MonoMac
Classification: Desktop
Component: Bindings ()
Version: unspecified
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2013-10-28 08:48 UTC by Paul Zander
Modified: 2015-02-18 14:34 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and 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 Links.

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.

Related Links:
Status:
RESOLVED ANSWERED

Description Paul Zander 2013-10-28 08:48:57 UTC
If an unmanaged program calls managed code and within this managed code the following property is retrieved:
    AppDomain.CurrentDomain.SetupInformation.ConfigurationFile
A null pointer is returned.

This behaviour is differnt from the Microsoft .NET framework that returns a valid string.
This string contains the full path of the managed code, extended with '.config'.
Comment 1 Paul Zander 2013-10-28 08:53:22 UTC
A type in the description.
The last line should be:
This string contains the full path of the UNMANAGED code, extended with
'.config'.

Note:
Tested with versin 3.2.3
Comment 2 Chris Hamons 2015-02-18 14:34:04 UTC
Paul,

I'm sorry for the extended delay in response on this bug. It was misfiled and overlooked until now.

I've tried to test this with Xamarin.Mac and mono 3.12 with a Classic application. When bundled with mmp, we have a native launcher spin up the managed code. Within in that property is now returning non-null. As no reproduction case was attached, this is the best validation I can do right now.

Given the length of time this has been open, I'm going to close as answered. Please reopen or open a new bug if you are still seeing this behavior.

Again, apologies on the delay in response.