I can submit my previous patch for snoop also. It removes functionality but 
fixes the crash. Should I submit it?

-------------------------------------------------------

Changelog:

- this patch should get rid of the remaining crashes in snoop. It fixes
SNOOP_GetProcAddress.

-------------------------------------------------------

COPYRIGHT: All original work contained in this email is released
under the terms of the old Wine license (LICENSE.OLD in the
distribution). This means that any new functions I have created can
be incorporated into a non LGPL Wine fork, for example. Any future
patches I submit can be considered to be release under the old
Wine license.


--- snoop.c.hq	Wed Mar 13 19:43:58 2002
+++ snoop.c	Wed Mar 13 19:45:28 2002
@@ -193,7 +193,14 @@
 		return origfun;
 	if (!SNOOP_ShowDebugmsgSnoop(dll->name,ordinal,name))
 		return origfun;
-	assert(ordinal < dll->nrofordinals);
+	/*assert(ordinal < dll->nrofordinals);*/
+
+	if(ordinal >= dll->nrofordinals)
+	  {
+	    ERR("%d >= %d, ordinal >= number of ordinals!\n", ordinal, dll->nrofordinals);
+	    return origfun;
+	  }
+
 	fun = dll->funs+ordinal;
 	if (!fun->name) 
 	  {

Reply via email to