[Mono-bugs] [Bug 659751] New: Stack Overflow In System.Diagnostics.TraceSource:.ctor(string) If Empty <sharedListeners/> Element Present In Application Configuration File

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Dec 15 15:14:31 EST 2010


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

https://bugzilla.novell.com/show_bug.cgi?id=659751#c0


           Summary: Stack Overflow In
                    System.Diagnostics.TraceSource:.ctor(string) If Empty
                    <sharedListeners/> Element Present In Application
                    Configuration File
    Classification: Mono
           Product: Mono: Class Libraries
           Version: 2.8.x
          Platform: x86-64
        OS/Version: Windows 7
            Status: NEW
          Severity: Critical
          Priority: P5 - None
         Component: System
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: martin_costello at talk21.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---


Created an attachment (id=404999)
 --> (http://bugzilla.novell.com/attachment.cgi?id=404999)
ZIP of VS2010 project to reproduce the issue and the console output log.

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2.4)
Gecko/20100611 Firefox/3.6.4

If an empty <sharedListeners/> element is present in the <system.diagnostics>
element of the application configuration file and a
System.Diagnostics.TraceSource instance is instatiated in user code, a stack
overflow appears to appear (based on output from --trace).

No StackOverflowException is thrown by the Mono runtime either (although I'm
not sure whether the resources would have been available to allow this to
happen successfully).

The issue disappears if the empty <sharedListener/> element is either removed
or commented out.

A text file is also attached showing the (truncated) console output from using
the --trace=N:System.Diagnostics switch when running the application, which
appears to show a stack overflow.

Reproducible: Always

Steps to Reproduce:
To reproduce the issue compile the sample application attached and execute
under the Mono runtime.
Actual Results:  
"mono.exe has stopped working" message is displayed by Windows OS and the
program exits.

Expected Results:  
The sample application should print a message to the console showing that a
TraceSource instance has been successfully instantiated.

The application could also have thrown a StackOverflowException when the root
issue was encountered, and thrown this to the try-catch block in the
application for handling (if possible).

Logging as critical as it causes a crash, despite how easy it is to work around
(i.e. commenting-out the element or deleting it entirely).

-- 
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