1// Check that fopen(NULL, "r") is ok.
2// RUN: %clang -O2 %s -o %t && %run %t
3#include <stdio.h>
4const char *fn = NULL;
5FILE *f;
6int main() { f = fopen(filename: fn, modes: "r"); }
7

source code of compiler-rt/test/sanitizer_common/TestCases/fopen_nullptr.c