[sanitizer] Fix file access modes in SanitizerCommon.InternalMmapWithOffset and SanitizerCommon.FileOps

llvm-svn: 232972
This commit is contained in:
Alexander Potapenko 2015-03-23 17:55:19 +00:00
parent d1801afeac
commit f0581dda03
1 changed files with 2 additions and 2 deletions

View File

@ -85,7 +85,7 @@ TEST(SanitizerCommon, FileOps) {
EXPECT_EQ(len2, internal_write(fd, str2, len2));
internal_close(fd);
openrv = OpenFile(tmpfile, WrOnly);
openrv = OpenFile(tmpfile, RdOnly);
EXPECT_FALSE(internal_iserror(openrv));
fd = openrv;
uptr fsize = internal_filesize(fd);
@ -134,7 +134,7 @@ TEST(SanitizerCommon, InternalMmapWithOffset) {
char tmpfile[128];
temp_file_name(tmpfile, sizeof(tmpfile),
"sanitizer_common.internalmmapwithoffset.tmp.");
uptr res = OpenFile(tmpfile, WrOnly);
uptr res = OpenFile(tmpfile, RdWr);
ASSERT_FALSE(internal_iserror(res));
fd_t fd = res;