From: Jeffrey Altman Date: Tue, 1 Sep 2009 00:08:53 +0000 (-0400) Subject: Windows: uninitialized variable X-Git-Tag: openafs-devel-1_5_63~61 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=c0e1cc0762eb7e49d72fdfecda168e72db55c3e8;p=packages%2Fo%2Fopenafs.git Windows: uninitialized variable Ensure that the index variable used to walk the fid history of the current evaluated path is always initialized. LICENSE MIT Reviewed-on: http://gerrit.openafs.org/389 Tested-by: Asanka Herath Reviewed-by: Asanka Herath Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman --- diff --git a/src/WINNT/afsd/cm_vnodeops.c b/src/WINNT/afsd/cm_vnodeops.c index 2754315fa..927b1846c 100644 --- a/src/WINNT/afsd/cm_vnodeops.c +++ b/src/WINNT/afsd/cm_vnodeops.c @@ -2038,9 +2038,10 @@ long cm_NameI(cm_scache_t *rootSCachep, clientchar_t *pathp, long flags, } if (code == 0 && linkScp != NULL) { - if (linkScp == cm_data.rootSCachep) + if (linkScp == cm_data.rootSCachep) { fid_count = 0; - else { + i = 0; + } else { for ( i=0; ifid, &fids[i]) ) { code = CM_ERROR_TOO_MANY_SYMLINKS;