Cleanup: apply `include-what-you-use` guideline for `close()`
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Thu, 5 Dec 2019 23:17:31 +0000 (18:17 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Thu, 13 Feb 2020 17:11:01 +0000 (12:11 -0500)
I saw that some files use the `close()` function but there are not
including a header for it. The `close()` function is defined by the
following header: <unistd.h>

So, to follow the best practice of including what is used in a file, I
added `#include <unistd.h>` in files using `close()`.

Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I07e104e957857c869576af7c2704e98584ecc763

liblttng-ust-ctl/ustctl.c
liblttng-ust/lttng-ust-abi.c
libringbuffer/shm.h

index 39c8baa4b4fea4b586a9323290b6287acd4e86f4..914ce94ea024c5ace40dccf405cbb5b80ed192be 100644 (file)
@@ -21,6 +21,7 @@
 #include <stdint.h>
 #include <string.h>
 #include <sys/mman.h>
+#include <unistd.h>
 
 #include <lttng/ust-config.h>
 #include <lttng/ust-ctl.h>
index 0459d7a3f29bf22fcef79f12605834b877feeb10..c060e2d9aaae49f033cf420f0155bb7a03d5d4c8 100644 (file)
@@ -39,6 +39,7 @@
 
 #define _LGPL_SOURCE
 #include <stdint.h>
+#include <unistd.h>
 
 #include <urcu/compiler.h>
 #include <urcu/list.h>
index b5d1343ac4d783369ea50c10708062910f89c2b0..d7393cd255edea3fc4aca79904b657096b7c6a80 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <stddef.h>
 #include <stdint.h>
+#include <unistd.h>
 #include <usterr-signal-safe.h>
 #include <urcu/compiler.h>
 #include "shm_types.h"
This page took 0.02691 seconds and 4 git commands to generate.