소스 검색

dont rely on random stack state to trigger this issue; force the default stat structs to alternative bit masks

Mike Frysinger 19 년 전
부모
커밋
297503eec5
1개의 변경된 파일3개의 추가작업 그리고 0개의 파일을 삭제
  1. 3 0
      test/stat/memcmp-stat.c

+ 3 - 0
test/stat/memcmp-stat.c

@@ -72,6 +72,9 @@ int main()
 	int fd;
 	struct stat fst, st;
 
+	memset(&fst, 0xAA, sizeof(fst));
+	memset(&st, 0x55, sizeof(st));
+
 	unlink(".testfile");
 	fd = open(".testfile", O_WRONLY | O_CREAT | O_EXCL, 0);
 	if (fd < 0) {