From 9613c6f9b0c2ee488f03107397a18be58a430cbe Mon Sep 17 00:00:00 2001 From: rncbc Date: Sun, 24 Apr 2016 15:16:06 +0100 Subject: [PATCH] - Drop "in"/"out" suffixes from alsa_midi slave driver port-names. --- drivers/alsa_midi/port.c | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/drivers/alsa_midi/port.c b/drivers/alsa_midi/port.c index d217310..9653fda 100644 --- a/drivers/alsa_midi/port.c +++ b/drivers/alsa_midi/port.c @@ -111,36 +111,32 @@ a2j_port_fill_name (struct a2j_port * port_ptr, int dir, snd_seq_client_info_t * /* entire client name is part of the port name so don't replicate it */ snprintf (port_ptr->name, sizeof(port_ptr->name), - "[%d:%d] %s (%s)", + "[%d:%d] %s", snd_seq_client_info_get_client (client_info_ptr), snd_seq_port_info_get_port (port_info_ptr), - port_name, - (dir == A2J_PORT_CAPTURE ? "out" : "in")); + port_name); } else { snprintf (port_ptr->name, sizeof(port_ptr->name), - "[%d:%d] %s %s (%s)", + "[%d:%d] %s %s", snd_seq_client_info_get_client (client_info_ptr), snd_seq_port_info_get_port (port_info_ptr), client_name, - port_name, - (dir == A2J_PORT_CAPTURE ? "out" : "in")); + port_name); } } else { if (strstr (port_name, client_name) == port_name) { /* entire client name is part of the port name so don't replicate it */ snprintf (port_ptr->name, sizeof(port_ptr->name), - "%s (%s)", - port_name, - (dir == A2J_PORT_CAPTURE ? "out" : "in")); + "%s", + port_name); } else { snprintf (port_ptr->name, sizeof(port_ptr->name), - "%s %s (%s)", + "%s %s", client_name, - snd_seq_port_info_get_name (port_info_ptr), - (dir == A2J_PORT_CAPTURE ? "out" : "in")); + snd_seq_port_info_get_name (port_info_ptr)); } }