[Numpy-svn] r3376 - trunk/numpy/core/src

numpy-svn at scipy.org numpy-svn at scipy.org
Sat Oct 21 00:48:22 CDT 2006


Author: oliphant
Date: 2006-10-21 00:48:11 -0500 (Sat, 21 Oct 2006)
New Revision: 3376

Modified:
   trunk/numpy/core/src/ufuncobject.c
Log:
Fix possible unitialized 'i' to fix #359

Modified: trunk/numpy/core/src/ufuncobject.c
===================================================================
--- trunk/numpy/core/src/ufuncobject.c	2006-10-20 12:32:23 UTC (rev 3375)
+++ trunk/numpy/core/src/ufuncobject.c	2006-10-21 05:48:11 UTC (rev 3376)
@@ -803,6 +803,7 @@
                         else if (rtypenums[0] == funcdata->arg_types[self->nin]) {
                                 i = nargs;
                         }
+			else i = -1;
                         if (i == nargs) {
                                 *function = funcdata->func;
                                 *data = funcdata->data;
@@ -831,6 +832,7 @@
                 else if (rtypenums[0] == self->types[j*nargs+self->nin]) {
                         i = nargs;
                 }
+		else i = -1;
                 if (i == nargs) {
                         *function = self->functions[j];
                         *data = self->data[j];



More information about the Numpy-svn mailing list