~ubuntu-branches/ubuntu/oneiric/eyed3/oneiric

« back to all changes in this revision

Viewing changes to debian/patches/02_delete_frame

  • Committer: Bazaar Package Importer
  • Author(s): Alexander Wirt
  • Date: 2006-11-18 01:47:38 UTC
  • mfrom: (1.2.1 upstream) (2.1.5 feisty)
  • Revision ID: james.westby@ubuntu.com-20061118014738-bcwcoe9gywrgorz2
New upstream version  

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/sh -e
2
 
## 01_eyed3_delete_frame by Alexander Wirt <formorer@debian.org>
3
 
##
4
 
## All lines beginning with `## DP:' are a description of the patch.
5
 
## DP: Fixes a bug when deleting a frame. Original patch was from 
6
 
## DP: Aaron Crane <debbugs@aaroncrane.co.uk>
7
 
 
8
 
if [ $# -ne 1 ]; then
9
 
    echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
10
 
    exit 1
11
 
fi
12
 
 
13
 
[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
14
 
patch_opts="${patch_opts:--f --no-backup-if-mismatch}"
15
 
 
16
 
case "$1" in
17
 
       -patch) patch $patch_opts -p0 < $0;;
18
 
       -unpatch) patch $patch_opts -p0 -R < $0;;
19
 
        *)
20
 
                echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
21
 
                exit 1;;
22
 
esac
23
 
 
24
 
exit 0
25
 
 
26
 
@DPATCH@
27
 
--- src/eyeD3/tag.py.orig   2005-03-20 11:38:24.000000000 +0000
28
 
+++ src/eyeD3/tag.py        2005-03-20 11:41:43.000000000 +0000
29
 
@@ -695,8 +695,9 @@
30
 
    def setDate(self, year, month = None, dayOfMonth = None,
31
 
                hour = None, minute = None, second = None, fid = None):
32
 
       if not year and not fid:
33
 
-          dateFrame = self.getDate;
34
 
-          self.frames.removeFramesByID(dateFrame.id);
35
 
+          dateFrame = self.getDate();
36
 
+          if dateFrame:
37
 
+              self.frames.removeFramesByID(dateFrame[0].header.id);
38
 
           return;
39
 
       elif not year:
40
 
           self.frames.removeFramesByID(fid);
41