[Mono-bugs] [Bug 383909] New: PathTooLongException not thrown by System.IO. DirectoryInfo() on MonoWindows

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Fri Apr 25 16:04:00 EDT 2008


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


           Summary: PathTooLongException not thrown by
                    System.IO.DirectoryInfo() on MonoWindows
           Product: Mono: Class Libraries
           Version: 1.9.0
          Platform: x86
        OS/Version: Windows XP
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: CORLIB
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: jfrayne at blizzard.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


This test was performed on the same machine and OS:

namespace PathTooLongTest
{
        class Program
        {
                static void Main(string[] args)
                {
                        try
                        {
                                string root =
"lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll";
                                System.IO.DirectoryInfo dir = new
System.IO.DirectoryInfo(root);
                                Console.WriteLine("No exception thrown!");
                        }
                        catch (System.IO.PathTooLongException ex)
                        {
                                Console.WriteLine(ex.GetType() + ": " +
ex.Message);
                        }
                        Console.Read();
                }
        }
}

Expected:
System.IO.PathTooLongException: The specified path, file name, or both are too
long. The fully qualified file name must be less than 260 characters, and the
directory name must be less than 248 characters.

Actual:
No exception thrown!


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