auth: Remove unecessary assignment
authorSimon Wilkinson <sxw@your-file-system.com>
Tue, 12 Feb 2013 12:19:42 +0000 (12:19 +0000)
committerDerrick Brashear <shadow@your-file-system.com>
Wed, 20 Feb 2013 18:23:27 +0000 (10:23 -0800)
When we're counting the number of keys available, we don't need to
actually extract each key entry - remove the unused assignment.

Caught by clang-analyzer.

Change-Id: I98a30afccaf9a455ea0a7e77e7ca0d648abe4e70
Reviewed-on: http://gerrit.openafs.org/9145
Reviewed-by: Marc Dionne <marc.c.dionne@gmail.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>

src/auth/keys.c

index 938c731..13bb647 100644 (file)
@@ -846,10 +846,8 @@ afsconf_GetAllKeys(struct afsconf_dir *dir, struct afsconf_typedKeyList **keys)
        typeEntry = opr_queue_Entry(typeCursor, struct keyTypeList, link);
        for (opr_queue_Scan(&typeEntry->kvnoList, kvnoCursor)) {
            kvnoEntry = opr_queue_Entry(kvnoCursor, struct kvnoList, link);
-           for (opr_queue_Scan(&kvnoEntry->subTypeList, subCursor)) {
-               subEntry = opr_queue_Entry(subCursor, struct subTypeList, link);
+           for (opr_queue_Scan(&kvnoEntry->subTypeList, subCursor))
                count++;
-           }
        }
     }