linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Carlos Manuelda <stormbyte@gmail.com>
To: linux-bluetooth@vger.kernel.org
Cc: David Carlos Manuelda <stormbyte@gmail.com>
Subject: [PATCH BlueZ 1/1] build: Clang fix - ISO C forbids nested functions
Date: Tue,  7 Aug 2018 16:09:33 +0200	[thread overview]
Message-ID: <20180807140933.11528-2-stormbyte@gmail.com> (raw)
In-Reply-To: <20180807140933.11528-1-stormbyte@gmail.com>

---
 profiles/midi/midi.c | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/profiles/midi/midi.c b/profiles/midi/midi.c
index 1ee5cb16f..f08728e4b 100644
--- a/profiles/midi/midi.c
+++ b/profiles/midi/midi.c
@@ -71,20 +71,20 @@ struct midi {
 	struct midi_write_parser midi_out;
 };
 
+static void foreach_cb(const struct midi_write_parser *parser, void *user_data) {
+	struct midi *midi = user_data;
+	bt_gatt_client_write_without_response(midi->client,
+	                                      midi->midi_io_handle,
+	                                      false,
+	                                      midi_write_data(parser),
+	                                      midi_write_data_size(parser));
+}
+
 static bool midi_write_cb(struct io *io, void *user_data)
 {
 	struct midi *midi = user_data;
 	int err;
 
-	void foreach_cb(const struct midi_write_parser *parser, void *user_data) {
-		struct midi *midi = user_data;
-		bt_gatt_client_write_without_response(midi->client,
-		                                      midi->midi_io_handle,
-		                                      false,
-		                                      midi_write_data(parser),
-		                                      midi_write_data_size(parser));
-	};
-
 	do {
 		snd_seq_event_t *event = NULL;
 
-- 
2.18.0


      reply	other threads:[~2018-08-07 14:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-07 14:09 [PATCH BlueZ 0/1] Fix compilation with clang David Carlos Manuelda
2018-08-07 14:09 ` David Carlos Manuelda [this message]

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=20180807140933.11528-2-stormbyte@gmail.com \
    --to=stormbyte@gmail.com \
    --cc=linux-bluetooth@vger.kernel.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 NNTP newsgroup(s).