public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
From: Ulf Hermann <ulf.hermann@qt.io>
To: <elfutils-devel@sourceware.org>
Subject: [PATCH] Include sys/types.h before fts.h
Date: Thu, 20 Apr 2017 13:26:00 -0000	[thread overview]
Message-ID: <49b18dc8-3a1a-9b3b-6cd7-15c9df8fed4a@qt.io> (raw)

The bad fts not only needs to be included before config.h, but also
requires various special types without including sys/types.h.

Signed-off-by: Ulf Hermann <ulf.hermann@qt.io>
---
 libdwfl/ChangeLog              | 4 ++++
 libdwfl/linux-kernel-modules.c | 4 ++++
 2 files changed, 8 insertions(+)

diff --git a/libdwfl/ChangeLog b/libdwfl/ChangeLog
index ede6d47..1ed9dd4 100644
--- a/libdwfl/ChangeLog
+++ b/libdwfl/ChangeLog
@@ -1,3 +1,7 @@
+2017-04-20  Ulf Hermann <ulf.hermann@qt.io>
+
+	* linux-kernel-modules.c: Include sys/types.h before fts.h
+
 2017-03-24  Mark Wielaard  <mark@klomp.org>
 
 	* linux-core-attach.c (core_next_thread): If n_namesz == 0 then
diff --git a/libdwfl/linux-kernel-modules.c b/libdwfl/linux-kernel-modules.c
index 7345e76..757eace 100644
--- a/libdwfl/linux-kernel-modules.c
+++ b/libdwfl/linux-kernel-modules.c
@@ -26,6 +26,10 @@
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+/* Include sys/types.h before fts. On some systems fts.h is not self
+   contained. */
+#include <sys/types.h>
+
 /* In case we have a bad fts we include this before config.h because it
    can't handle _FILE_OFFSET_BITS.
    Everything we need here is fine if its declarations just come first.  */
-- 
2.1.4

             reply	other threads:[~2017-04-20 13:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-20 13:26 Ulf Hermann [this message]
2017-04-20 14:37 ` Dmitry V. Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=49b18dc8-3a1a-9b3b-6cd7-15c9df8fed4a@qt.io \
    --to=ulf.hermann@qt.io \
    --cc=elfutils-devel@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).