소스 검색

610281 - fix coverity Defect Type: Control flow issues

https://bugzilla.redhat.com/show_bug.cgi?id=610281

11817 DEADCODE Triaged Unassigned Bug Moderate Fix Required
NSUniqueAttr_Init() ds/ldap/servers/plugins/uiduniq/uid.c

Comment:
NSUniqueAttr_Init declared err twice.  One at the top and another
in BEGIN - END (do - while loop).  The second err in the do - while
loop is trashed when it gets out of the loop.  Regardless of the
result in the do - while loop, err = 0 (success) was returned to
the caller.

We are removing the second err in the BEGIN (== do - while) scope.
945 int err;
Noriko Hosoi 15 년 전
부모
커밋
d1946d8f5c
1개의 변경된 파일0개의 추가작업 그리고 1개의 파일을 삭제
  1. 0 1
      ldap/servers/plugins/uiduniq/uid.c

+ 0 - 1
ldap/servers/plugins/uiduniq/uid.c

@@ -942,7 +942,6 @@ NSUniqueAttr_Init(Slapi_PBlock *pb)
   int err = 0;
 
   BEGIN
-    int err;
     int argc;
     char **argv;