Browse Source

AP_Common: add missing O_CLOEXEC definition

O_CLOEXEC is not available on Nuttx, nor it makes sense there. Define it
as 0, so we can use it in code.
mission-4.1.18
Lucas De Marchi 8 years ago
parent
commit
2e4c1818a3
  1. 9
      libraries/AP_Common/missing/fcntl.h

9
libraries/AP_Common/missing/fcntl.h

@ -0,0 +1,9 @@ @@ -0,0 +1,9 @@
#include_next <fcntl.h>
/*
* we only want to define as 0 for those targets in which it doesn't make
* sense
*/
#if defined(HAVE_OCLOEXEC) && HAVE_OCLOEXEC == 0
#define O_CLOEXEC 0
#endif
Loading…
Cancel
Save