소스 검색

core: safety check accessing variables in dbg message during fixup operation

Daniel-Constantin Mierla 11 년 전
부모
커밋
0bda1dc823
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      switch.c

+ 2 - 2
switch.c

@@ -538,8 +538,8 @@ static int fix_match(struct action* t)
 			if (default_found){
 				LOG(L_ERR, "ERROR: fix_match: more then one \"default\""
 						" label found (%d, %d)\n",
-						c->ct_rve->fpos.s_line,
-						c->ct_rve->fpos.s_col);
+						(c->ct_rve)?c->ct_rve->fpos.s_line:0,
+						(c->ct_rve)?c->ct_rve->fpos.s_col:0);
 				ret=E_UNSPEC;
 				goto error;
 			}