]> git.proxmox.com Git - rustc.git/blame - src/compiler-rt/test/msan/initgroups.cc
Imported Upstream version 1.6.0+dfsg1
[rustc.git] / src / compiler-rt / test / msan / initgroups.cc
CommitLineData
92a42be0 1// RUN: %clangxx_msan -O0 %s -o %t && %run %t
1a4d82fc
JJ
2
3#include <sys/types.h>
4#include <grp.h>
92a42be0 5#include <unistd.h> // FreeBSD declares initgroups() here.
1a4d82fc
JJ
6
7int main(void) {
8 initgroups("root", 0);
9 // The above fails unless you are root. Does not matter, MSan false positive
10 // (which we are testing for) happens anyway.
11 return 0;
12}