1 // RUN: %clang_analyze_cc1 -analyzer-checker=core,alpha.unix.Stream -verify %s
3 typedef struct _IO_FILE
FILE;
4 extern FILE *fopen(const char *path
, const char *mode
);
11 void *fopen(X x
, const char *mode
) {
17 void *p
= fopen(X1
, "oo");
21 FILE *f
= fopen("file", "r");
22 } // expected-warning {{Opened stream never closed. Potential resource leak}}