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


           Summary: GDI+ status: InvalidParameter on Bitmap.ctor(Stream)
           Product: Mono: Class Libraries
           Version: SVN
          Platform: i586
        OS/Version: openSUSE 10.3
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Sys.Drawing.
        AssignedTo: [email protected]
        ReportedBy: [EMAIL PROTECTED]
         QAContact: [email protected]
          Found By: ---


The following example (from FreeTrain PlatformPropertyDialog.resx) results in
an ArgumentException (with libgdiplus r95661):

--------
using System;
using System.Drawing;
using System.IO;

public class Test
{
        public static void Main ()
        {
                string base64 = @"
       
R0lGODlhDgANAPIAAP//AICAgP8A/4AAAAAAAAAAAAAAAAAAACH5BAEAAAIALAAAAAAOAA0AAAMqKLrc
        HcE9AIhUgVIrMxlVRw3E5mQVGDIoQGocps2r0KYzd9M14f/AyyUBADs=";
                byte [] bytes = Convert.FromBase64String (base64);
                Bitmap bmp = new Bitmap (new MemoryStream (bytes));
        }
}

--------
Unhandled Exception: System.ArgumentException: A null reference or invalid
value was found [GDI+ status: InvalidParameter]
  at System.Drawing.GDIPlus.CheckStatus (Status status) [0x00000] 
  at System.Drawing.Image.InitFromStream (System.IO.Stream stream) [0x00000] 
  at System.Drawing.Bitmap..ctor (System.IO.Stream stream, Boolean useIcm)
[0x00000] 
  at System.Drawing.Bitmap..ctor (System.IO.Stream stream) [0x00000] 
  at (wrapper remoting-invoke-with-check) System.Drawing.Bitmap:.ctor
(System.IO.Stream)

--------
It works fine under .NET.


-- 
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.
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to