Fix problem in reading long options from the command line.
authoreitan <eitan@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Thu, 20 Oct 2005 11:57:14 +0000 (11:57 +0000)
committereitan <eitan@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Thu, 20 Oct 2005 11:57:14 +0000 (11:57 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@128 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/opensm/user/libvendor/winosm_common.c

index 9523bea..a12410a 100644 (file)
@@ -74,6 +74,7 @@ int getopt_long_only(int argc, char *const*argv,
         if (strcmp (tok, longopts[i].name) == 0)
                {
             /* We have a match */             
+             if (longindex != NULL )
                 *longindex = i;
               
                 if (longopts[i].flag != NULL) {