All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Vorel <pvorel@suse.cz>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH 2/3] fanotify: Fix build on undefined struct file_handle
Date: Tue, 12 Jan 2021 20:30:38 +0100	[thread overview]
Message-ID: <20210112193039.12506-3-pvorel@suse.cz> (raw)
In-Reply-To: <20210112193039.12506-1-pvorel@suse.cz>

This fixes error:
fanotify09.c:201:32: error: dereferencing pointer to incomplete type ?struct file_handle?
  201 |  filename = (char *)file_handle->f_handle + file_handle->handle_bytes;

Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
 testcases/kernel/syscalls/fanotify/fanotify.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testcases/kernel/syscalls/fanotify/fanotify.h b/testcases/kernel/syscalls/fanotify/fanotify.h
index 8907db052..039379961 100644
--- a/testcases/kernel/syscalls/fanotify/fanotify.h
+++ b/testcases/kernel/syscalls/fanotify/fanotify.h
@@ -12,8 +12,8 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <errno.h>
-#include <fcntl.h>
 #include <sys/fanotify.h>
+#include "lapi/fcntl.h"
 
 int safe_fanotify_init(const char *file, const int lineno,
 	unsigned int flags, unsigned int event_f_flags)
-- 
2.29.2


  parent reply	other threads:[~2021-01-12 19:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-12 19:30 [LTP] [PATCH 0/3] Build fix undefined struct file_handle Petr Vorel
2021-01-12 19:30 ` [LTP] [PATCH 1/3] lapi: Move struct file_handle into lapi/fcntl.h Petr Vorel
2021-01-12 19:30 ` Petr Vorel [this message]
2021-01-12 19:30 ` [LTP] [PATCH 3/3] syscalls: Remove unused include <fcntl.h> Petr Vorel
2021-01-13  2:23 ` [LTP] [PATCH 0/3] Build fix undefined struct file_handle Yang Xu
2021-01-13  6:33   ` Petr Vorel

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=20210112193039.12506-3-pvorel@suse.cz \
    --to=pvorel@suse.cz \
    --cc=ltp@lists.linux.it \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.