[Mono-bugs] [Bug 640688] New: Serialization shouldn't call Equals/GetHashCode on objects

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Sep 21 01:23:54 EDT 2010



           Summary: Serialization shouldn't call Equals/GetHashCode on
    Classification: Mono
           Product: Mono: Class Libraries
           Version: 2.8.x
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: CORLIB
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: jeroen at sumatra.nl
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---

User-Agent:       Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64;

The following program runs on .NET but fails on Mono:

using System;
using System.Runtime.Serialization.Formatters.Binary;
using System.IO;

class Program
    static void Main(string[] args)
        BinaryFormatter bf = new BinaryFormatter();
        bf.Serialize(Stream.Null, new Program());

    public override bool Equals(object obj)
        throw new Exception();

    public override int GetHashCode()
        throw new Exception();

Reproducible: Always

Steps to Reproduce:

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