sanitizer_common: fix up onprint.cpp test
authorDmitry Vyukov <dvyukov@google.com>
Wed, 27 Oct 2021 16:01:38 +0000 (18:01 +0200)
committerDmitry Vyukov <dvyukov@google.com>
Wed, 27 Oct 2021 16:17:15 +0000 (18:17 +0200)
commit910aeed77e92dd313cb3f7928803d112154ae5aa
treeb3070e1f23c157e65bbb81767b669a039c4a12fa
parent8f5cb64c7147c27953933dbaea107454ff066ed1
sanitizer_common: fix up onprint.cpp test

Commit D112602 ("sanitizer_common: tighten on_print hook test")
changed fopen to open in this test. fopen created the file
if if does not exist, but open does not. This was unnoticed
during local testing because lit is not hermetic and reuses
files from previous runs, but it started failing on bots.
Fix the open call.

Reviewed By: melver

Differential Revision: https://reviews.llvm.org/D112630
compiler-rt/test/sanitizer_common/TestCases/onprint.cpp