brintos

brintos / llvm-project-archived public Read only

0
0
Text · 373 B · d8ba8ca Raw
18 lines · cpp
1// RUN: %clangxx_msan -O0 -g %s -o %t && %run %t2 3// ftime() is deprecated on FreeBSD and NetBSD.4// UNSUPPORTED: target={{.*(freebsd|netbsd).*}}5 6#include <assert.h>7#include <sys/timeb.h>8 9#include <sanitizer/msan_interface.h>10 11int main(void) {12  struct timeb tb;13  int res = ftime(&tb);14  assert(!res);15  assert(__msan_test_shadow(&tb, sizeof(tb)) == -1);16  return 0;17}18