blob: 705ca2e981cb21376c6405f4e9a37b6acafc085f [file] [log] [blame]
// On Darwin, the man page states that "both fputs() and puts() print `(null)'
// if str is NULL."
//
// RUN: %clangxx -g %s -o %t && %run %t | FileCheck %s
// CHECK: {{^\(null\)---\(null\)$}}
#include <assert.h>
#include <stdio.h>
int main(void) {
assert(fputs(NULL, stdout) >= 0);
fputs("---", stdout);
assert(puts(NULL) >= 0);
return 0;
}