Public bug reported:

I'm running Ubuntu Quantal
Description:    Ubuntu 12.10
Release:        12.10

 and installed the following packages
pymtp 0.0.4-4
libmtp-common 1.1.4-1
libmtp-runtime 1.1.4-1

Executing the script : /usr/share/doc/python-
pymtp/examples/deviceinfo.py ends in a segmentation fault.

After some diving into the code I noticed a bug in pymtp.py. It does not
map to libmtp.h. The modificationdate field has been overlooked. After
changing pymtp.py like below

*** 203,208 ****
--- 203,209 ----
                        ("usecount", ctypes.c_uint32),
                        ("filesize", ctypes.c_uint64),
                        ("filetype", ctypes.c_int),
+                       ("modificationdate", ctypes.c_uint32),
                        ("next", ctypes.POINTER(LIBMTP_Track))]

It behaved as designed.

The line I added needs revision as this would not work on a 64bit
machine. But as I'm new to python I don't know how to put in the right
code. For my hardware this worked ;-)

Kind regards

Paul

$ apt-cache policy python-pymtp
python-pymtp:
  Installed: 0.0.4-4
  Candidate: 0.0.4-4
  Version table:
 *** 0.0.4-4 0
        500 http://be.archive.ubuntu.com/ubuntu/ quantal/universe i386 Packages
        100 /var/lib/dpkg/status
$ apt-cache policy libmtp-common
libmtp-common:
  Installed: 1.1.4-1
  Candidate: 1.1.4-1
  Version table:
 *** 1.1.4-1 0
        500 http://be.archive.ubuntu.com/ubuntu/ quantal/main i386 Packages
        100 /var/lib/dpkg/status
$ apt-cache policy libmtp-runtime
libmtp-runtime:
  Installed: 1.1.4-1
  Candidate: 1.1.4-1
  Version table:
 *** 1.1.4-1 0
        500 http://be.archive.ubuntu.com/ubuntu/ quantal/main i386 Packages
        100 /var/lib/dpkg/status

** Affects: pymtp (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1098095

Title:
  LIBMTP_Get_Tracklisting_With_Callback causes segmentation fault

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/pymtp/+bug/1098095/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to