[Mono-bugs] [Bug 34909][Nor] New - Array.IndexOf() fails for string[] and object[]

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
3 Dec 2002 05:40:58 -0000


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by mathpup@mylinuxisp.com.

http://bugzilla.ximian.com/show_bug.cgi?id=34909

--- shadow/34909	Tue Dec  3 00:40:58 2002
+++ shadow/34909.tmp.22034	Tue Dec  3 00:40:58 2002
@@ -0,0 +1,52 @@
+Bug#: 34909
+Product: Mono/Class Libraries
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: CORLIB
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: mathpup@mylinuxisp.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Array.IndexOf() fails for string[] and object[]
+
+Description of Problem: 
+ 
+Array.IndexOf() gives an null reference exception when called on an array of strings or 
+objects. 
+ 
+Steps to reproduce the problem: 
+1. Compile 'indexof.cs' attached. 
+2. Run 'indexof.exe' 
+3.  
+ 
+Actual Results: 
+ 
+Output: 
+Unhandled Exception: System.NullReferenceException: A null value was found where an 
+object instance was required 
+in <0x00125> 00 System.Array:IndexOf (System.Array,object,int,int) 
+in <0x0005b> 00 System.Array:IndexOf (System.Array,object) 
+in <0x00031> 00 .Testing:Main () 
+ 
+ 
+ 
+Expected Results: 
+ 
+Output:  
+ 
+-1 
+ 
+How often does this happen?  
+ 
+Always 
+ 
+Additional Information: 
+ 
+Works correctly with Rotor.