Sfoglia il codice sorgente

matrix: don't do db init for rank==proc_init and tcp main

Daniel-Constantin Mierla 14 anni fa
parent
commit
24731c59cd
1 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 2 0
      modules/matrix/matrix.c

+ 2 - 0
modules/matrix/matrix.c

@@ -597,6 +597,8 @@ static int mod_init(void)
 
 static int child_init(int rank)
 {
+	if(rank==PROC_INIT || rank==PROC_TCP_MAIN)
+		return 0;
 	if (matrix_db_open() != 0) return -1;
 	return 0;
 }