소스 검색

ldap(k): connect to server for negative ranks

- there are some processes with negative rank that need connection to
  ldap server, like timers
- reported by Pan Christensen
Daniel-Constantin Mierla 14 년 전
부모
커밋
6faec77af3
1개의 변경된 파일2개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 3
      modules_k/ldap/ldap_mod.c

+ 2 - 3
modules_k/ldap/ldap_mod.c

@@ -157,10 +157,9 @@ static int child_init(int rank)
 	int i = 0, ld_count = 0;
 	char* ld_name;
 	
-	/* don't do anything for non-worker process */
-	if (rank < 1) {
+	/* don't do anything for non-worker processes */
+	if (rank==PROC_INIT || rank==PROC_MAIN || rank==PROC_TCP_MAIN)
 		return 0;
-	}
 
 	/*
 	* build ld_sessions and connect all sessions