소스 검색

debugger: safety check for pid list

- some event route blocks can be executed before all children
  initialization and the internal pid list structure is not created,
  disable debugging in this case
Daniel-Constantin Mierla 14 년 전
부모
커밋
35ef4b0d8f
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      modules/debugger/debugger_api.c

+ 1 - 1
modules/debugger/debugger_api.c

@@ -240,7 +240,7 @@ int dbg_cfg_trace(void *data)
 	a = (struct action *)srevp[0];
 	msg = (struct sip_msg *)srevp[1];
 
-	if(a==NULL || msg==NULL)
+	if(a==NULL || msg==NULL || _dbg_pid_list==NULL)
 		return 0;
 
 	an = dbg_get_action_name(a);