[Mono-devel-list] [PATCH] Fix null reference exceptions in System.Data.DataView
tsureshkumar at novell.com
Wed Jul 6 08:21:01 EDT 2005
Marc Haisenko wrote:
> Hi folks,
> I just noticed that a bug in DataView.cs is still/again present in
> revision (r46988, svn://svn.myrealbox.com/source/trunk/mcs/)
> The problem is that a variable, rowCache, is often set to null but no
> checks are done. That way a fresh instance of DataView throws a
> NullReferenceException e.g. when reading the Count property as it
> "return rowCache.Length;".
> The fix is to never set the variable to null but to an empty array.
> attached patch implements this fix (only three lines need that fix).
> already sent a patch to fix the very same bug on 11.11.2004, it seems
> never got included...
FYI, the patch had been in earlier. See the changelog
2004-12-01 Miguel de Icaza <miguel at ximian.com>
* DataView.cs: Patch from Marc Haisenko that ensures that
is never null.
somehow, due to some other fixes/re-org/cleanup the patch went cleaned
More information about the Mono-devel-list