Fix the following checkpatch.pl warning:
- else is not generally useful after a break or return
Signed-off-by: Domagoj Trsan <domagoj.trsan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
static int midibuf_message_length(unsigned char code)
{
static int midibuf_message_length(unsigned char code)
{
else if (code < 0xf0) {
static const int length[] = { 3, 3, 3, 3, 2, 2, 3 };
else if (code < 0xf0) {
static const int length[] = { 3, 3, 3, 3, 2, 2, 3 };
- return length[(code >> 4) - 8];
+
+ message_length = length[(code >> 4) - 8];
} else {
/*
Note that according to the MIDI specification 0xf2 is
} else {
/*
Note that according to the MIDI specification 0xf2 is
static const int length[] = { -1, 2, -1, 2, -1, -1, 1, 1, 1, 1,
1, 1, 1, -1, 1, 1
};
static const int length[] = { -1, 2, -1, 2, -1, -1, 1, 1, 1, 1,
1, 1, 1, -1, 1, 1
};
- return length[code & 0x0f];
+ message_length = length[code & 0x0f];
+
+ return message_length;
}
static int midibuf_is_empty(struct midi_buffer *this)
}
static int midibuf_is_empty(struct midi_buffer *this)