From: Francis Deslauriers Date: Tue, 3 Dec 2019 20:47:24 +0000 (-0500) Subject: Cleanup: apply `include-what-you-use` guideline for `mbstate_t` X-Git-Tag: v2.13.0-rc1~548 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=9f18918b747c4787f291fdcdd67bb1f21ee8efce;p=lttng-ust.git Cleanup: apply `include-what-you-use` guideline for `mbstate_t` I saw that some files use the `mbstate_t` type but there are not including a header for it. The `mbstate_t` type is defined by the following header: So, to follow the best practice of including what is used in a file, I added `#include ` in files using `mbstate_t`. Signed-off-by: Francis Deslauriers Signed-off-by: Mathieu Desnoyers Change-Id: I103d144ede1a8488d2662d3b8ba5337accafda99 --- diff --git a/snprintf/various.h b/snprintf/various.h index 64f1db1f..13d29b7b 100644 --- a/snprintf/various.h +++ b/snprintf/various.h @@ -36,6 +36,7 @@ #include #include #include +#include struct __lttng_ust_sbuf { unsigned char *_base; diff --git a/snprintf/vfprintf.c b/snprintf/vfprintf.c index 896a8840..4ac63c3c 100644 --- a/snprintf/vfprintf.c +++ b/snprintf/vfprintf.c @@ -51,6 +51,7 @@ #include #include #include +#include #include "local.h" #include "fvwrite.h" diff --git a/snprintf/wcio.h b/snprintf/wcio.h index 453a41b1..ddaf9e4b 100644 --- a/snprintf/wcio.h +++ b/snprintf/wcio.h @@ -33,6 +33,7 @@ #define _WCIO_H_ #include +#include /* minimal requirement of SUSv2 */ #define WCIO_UNGETWC_BUFSIZE 1