pmidi use wrong device number

Bug #316265 reported by Mitsuya Shibata on 2009-01-12
10
Affects Status Importance Assigned to Milestone
pmidi (Debian)
Fix Released
Unknown
pmidi (Ubuntu)
Medium
Unassigned

Bug Description

Binary package hint: pmidi

This bug was originally reported by fueryuejing.
 https://bugs.launchpad.net/ubuntu-jp-improvement/+bug/307143

pmidi use wrong device number on multi port midi file and send SysEx
all ports. This problem is caused in src/midiread.c:257-264.
Further information is following:

a. Device num (msp->device) and port num (msp->port) is served to deal multi
 port if channel num is over 16. For example, if port num is 0 and
 channel is 2, then device num become 16*0+(2-1)=1. If port num is 2 and
 channel is 14, then device num become 16*2+(14-1)=45.
b. Therefore if status byte (status) is channel message (0x80-0xef),
 destination device num of message must be "port(msp>-port)*16+channel(ch)".
c. However if status byte is SysEx message (0xf0-0xff), device num must eqaul
 to "port(msp->port)*16", because this message is not channel specified.
d. In source code at this time, if pmidi is recived SysEx message,
 debice num(msp->device) will be 0, even use any port and channel num.
e. This patch is that default device num set to
 "port(msp>-port)*16+channel(ch)".
 And add channel num to device num, if message is not SysEx.

Related branches

Mitsuya Shibata (cosmos-door) wrote :
Mitsuya Shibata (cosmos-door) wrote :

pmidi (1.6.0-4build2) jaunty; urgency=low

  * Add debian/patches/01-multiport.dpatch
   - Deal multiport midi file (LP: #316265)
  * Modify debin/control file
   - Bump up Standards-Version to 3.8.0
   - Add ${misc:Depends} to Depends field
   - Move Homepage field to first paragraph

Luca Falavigna (dktrkranz) wrote :

Thanks for the patch! Could this be forwarded to Debian or upstream? It could be interesting to see their opinions too.

Changed in pmidi:
importance: Undecided → Medium

Thank you for comment.

2009/1/18 Luca Falavigna <email address hidden>:
> Thanks for the patch! Could this be forwarded to Debian or upstream? It
> could be interesting to see their opinions too.
>

I had send the patch to upstream author.
And his reply was:
> I have applied the patch to CVS and committed it.

However there is not new upstream release yet.

Iain Lane (laney) wrote :

Hi,

I am going to upload this with a couple of changes

 - Need to update the maintainer for Ubuntu-modified package
 - Do not apply lintian fixes. Thanks for doing this, but we generally try to keep the diff over Debian as small as possible, and as these aren't causing problems for us, we don't need to take them in Ubuntu.
 - Version should be ubuntu1 when we make changes. The "build1" version indicated a no-change rebuild, but here we are making actual modifications to the source.

Could you attach the diff (minus the changelog entry, but including the lintian fixes) to the Debian bug so that we can hopefully sync next time?

Thanks for your contribution to Ubuntu.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pmidi - 1.6.0-4ubuntu1

---------------
pmidi (1.6.0-4ubuntu1) jaunty; urgency=low

  * Add debian/patches/01-multiport.dpatch
   - Deal multiport midi file (LP: #316265)

 -- Mitsuya Shibata <email address hidden> Mon, 12 Jan 2009 14:38:44 +0900

Changed in pmidi:
status: New → Fix Released
Changed in pmidi:
status: Unknown → New
Changed in pmidi (Debian):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.