소스 검색

Bug 622903 - fix coverity Defect Type: Code maintainability issues

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

Comment:
Pointer "replica" returned by "object_get_data(prp->replica_object)"
(line 502) is never used.  In "case STATE_READY_TO_ACQUIRE", Replica
object "replica" is not needed.
Noriko Hosoi 15 년 전
부모
커밋
9a6187a33a
1개의 변경된 파일1개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 2
      ldap/servers/plugins/replication/windows_inc_protocol.c

+ 1 - 2
ldap/servers/plugins/replication/windows_inc_protocol.c

@@ -499,7 +499,6 @@ windows_inc_run(Private_Repl_Protocol *prp)
 				/* ONREPL - at this state we unconditionally acquire the replica
 				   ignoring all events. Not sure if this is good */
 				object_acquire(prp->replica_object);
-				replica = object_get_data(prp->replica_object);
 						
 				rc = windows_acquire_replica(prp, &ruv , (run_dirsync == 0) /* yes, check the consumer RUV for incremental, but not if we're going to dirsync afterwards */);
 
@@ -539,7 +538,7 @@ windows_inc_run(Private_Repl_Protocol *prp)
 								prp->last_acquire_response_code, NULL);
 				  }
 						
-				object_release(prp->replica_object); replica = NULL;
+				object_release(prp->replica_object);
 				break;
 
 		case STATE_BACKOFF_START: