From 5388e1425d361a52728ce113fb31fb27f7e5539c Mon Sep 17 00:00:00 2001 From: Simon Wilkinson Date: Fri, 11 Jun 2010 23:50:29 +0100 Subject: [PATCH] libadmin: Don't use undefined value If IsValidCellHandle returns false, then we can jump to fail_pts_GroupMemberRemove, and end up using a value for ids.idlist_val which hasn't been defined. Fix this. Caught by clang-analyzer. Change-Id: I030d155f9ad2481250e84c31d4d7d26cb39a9c61 Reviewed-on: http://gerrit.openafs.org/2136 Reviewed-by: Russ Allbery Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- src/libadmin/pts/afs_ptsAdmin.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/libadmin/pts/afs_ptsAdmin.c b/src/libadmin/pts/afs_ptsAdmin.c index 342a9d3496..c74e897136 100644 --- a/src/libadmin/pts/afs_ptsAdmin.c +++ b/src/libadmin/pts/afs_ptsAdmin.c @@ -1479,6 +1479,8 @@ pts_GroupMemberRemove(const void *cellHandle, const char *userName, afs_cell_handle_p c_handle = (afs_cell_handle_p) cellHandle; idlist ids; + ids.idlist_val = NULL; + /* * Validate arguments */