Fix a typo in the condition to check if a midi port is referenced,

causing the port to be closed prematurely
This commit is contained in:
Alexandre Ratchov 2013-05-09 17:12:13 +02:00
parent 0f2025bd71
commit 1129bb8a7b
1 changed files with 1 additions and 1 deletions

View File

@ -512,7 +512,7 @@ port_unref(struct port *c)
#endif
for (rxmask = 0, i = 0; i < MIDI_NEP; i++)
rxmask |= midi_ep[i].txmask;
if ((rxmask & c->midi->self) == 0 && c->state == PORT_INIT && !c->hold)
if ((rxmask & ~c->midi->self) == 0 && c->state == PORT_INIT && !c->hold)
port_drain(c);
}