aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrene <rene@FreeBSD.org>2013-09-11 05:07:38 +0800
committerrene <rene@FreeBSD.org>2013-09-11 05:07:38 +0800
commit8a8f767a247d47f6100b5946d98c7aa7267bf6cc (patch)
tree06ee0383518e5a5312535980acc89fd585af93bc
parent5db01dfb307d489babadf43276652e0819c06cb4 (diff)
downloadfreebsd-ports-gnome-8a8f767a247d47f6100b5946d98c7aa7267bf6cc.tar.gz
freebsd-ports-gnome-8a8f767a247d47f6100b5946d98c7aa7267bf6cc.tar.zst
freebsd-ports-gnome-8a8f767a247d47f6100b5946d98c7aa7267bf6cc.zip
Do not crash on a non-numeric argument to the 'album' or 'artist' command.
Bump PORTREVISION
-rw-r--r--multimedia/spotify-websocket-api/Makefile2
-rw-r--r--multimedia/spotify-websocket-api/files/patch-clients__respotify__respotify.py16
2 files changed, 12 insertions, 6 deletions
diff --git a/multimedia/spotify-websocket-api/Makefile b/multimedia/spotify-websocket-api/Makefile
index a86ae31b89c3..ef2fffa75a5c 100644
--- a/multimedia/spotify-websocket-api/Makefile
+++ b/multimedia/spotify-websocket-api/Makefile
@@ -3,7 +3,7 @@
PORTNAME= SpotifyWebsocketAPI
PORTVERSION= 0.2
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= multimedia python
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
diff --git a/multimedia/spotify-websocket-api/files/patch-clients__respotify__respotify.py b/multimedia/spotify-websocket-api/files/patch-clients__respotify__respotify.py
index 97559e8e16a8..ca888d2f9e74 100644
--- a/multimedia/spotify-websocket-api/files/patch-clients__respotify__respotify.py
+++ b/multimedia/spotify-websocket-api/files/patch-clients__respotify__respotify.py
@@ -1,5 +1,5 @@
---- ./clients/respotify/respotify.py.orig 2013-09-10 22:10:39.000000000 +0200
-+++ ./clients/respotify/respotify.py 2013-09-10 22:11:58.000000000 +0200
+--- ./clients/respotify/respotify.py.orig 2013-08-08 08:45:21.000000000 +0200
++++ ./clients/respotify/respotify.py 2013-09-10 23:04:36.000000000 +0200
@@ -88,8 +88,10 @@
print "Playlists\n"
index = 1
@@ -13,25 +13,31 @@
else:
try:
if len(rootlist) >= int(args[0][0]):
-@@ -115,7 +117,7 @@
+@@ -115,7 +117,10 @@
def command_album(*args):
- if args[0][0] == "" or current_playlist is None:
+ if len(*args) == 0 or args[0][0] == "" or current_playlist is None:
++ return
++
++ if type(args[0][0]) != int:
return
index = int(args[0][0])-1
-@@ -127,7 +129,7 @@
+@@ -127,7 +132,10 @@
def command_artist(*args):
- if args[0][0] == "" or current_playlist is None:
+ if len(*args) == 0 or args[0][0] == "" or current_playlist is None:
++ return
++
++ if type(args[0][0]) != int:
return
index = int(args[0][0])-1
-@@ -278,7 +280,7 @@
+@@ -278,7 +286,7 @@
if spotify.logged_in():
os.system("kill `pgrep -f respotify-helper` &> /dev/null")
uri_resolver = subprocess.Popen([sys.executable, "respotify-helper.py",