* icall.c: there might be ignored whitespace after the last '='. This
fixes length computation and bug #75840.
svn path=/trunk/mono/; revision=48500
+2005-08-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
+
+ * icall.c: there might be ignored whitespace after the last '='. This
+ fixes length computation and bug #75840.
+
2005-08-18 Zoltan Varga <vargaz@freemail.hu>
* assembly.c (mono_assembly_load_full): Consider .exe extension as
well. Fixes #75809.
- * reflection.c (create_custom_attr): Fix unmanaged memory leak. Fixes #75784.
+ * reflection.c (create_custom_attr): Fix unmanaged memory leak. Fixes
+ #75784.
* reflection.c (create_custom_attr_data): Ditto.
* mono/metadata/assembly.c (load_metadata_ptrs): Fix for Beta2
+
gint ignored;
gint i;
gunichar2 c;
+ gunichar2 last, prev_last;
gint olength;
MonoArray *result;
guchar *res_ptr;
MonoException *exc;
ignored = 0;
+ last = prev_last = 0;
for (i = 0; i < ilength; i++) {
c = start [i];
if (isspace (c)) {
"System", "FormatException",
"Invalid character found.");
mono_raise_exception (exc);
+ } else {
+ prev_last = last;
+ last = c;
}
}
}
olength = (olength * 3) / 4;
- if (start [ilength - 1] == '=')
+ if (last == '=')
olength--;
- if (start [ilength - 2] == '=')
+ if (prev_last == '=')
olength--;
result = mono_array_new (mono_domain_get (), mono_defaults.byte_class, olength);