1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-10-18 02:19:39 +00:00

Explicitly include semaphore.h for struct _sem in fusefs setattr test

In libc++'s __threading_support header the semaphore.h header was
implicitly included, but from version 14 onwards, this is no longer the
case, resulting in compile errors:

tests/sys/fs/fusefs/setattr.cc:740:8: error: variable has incomplete type 'sem_t' (aka '_sem')
        sem_t sem;
              ^
tests/sys/fs/fusefs/utils.hh:33:8: note: forward declaration of '_sem'
struct _sem;
       ^

MFC after:	3 days

(cherry picked from commit c9cabf9aa6)
This commit is contained in:
Dimitry Andric 2022-02-06 17:07:16 +01:00
parent 4cd49eda1f
commit 01cccd7048

View File

@ -34,6 +34,7 @@ extern "C" {
#include <sys/stat.h> #include <sys/stat.h>
#include <fcntl.h> #include <fcntl.h>
#include <semaphore.h>
} }
#include "mockfs.hh" #include "mockfs.hh"