gnu: emacs-consult: Fix grammar.
[jackhill/guix/guix.git] / gnu / packages / patches / wicd-get-selected-profile-fix.patch
CommitLineData
ae4784af
MW
1Fix copied from https://bugs.launchpad.net/wicd/+bug/1421918/comments/2
2
3--- wicd-1.7.3/curses/wicd-curses.py 2014-12-21 16:57:33 +0000
4+++ wicd-1.7.3/curses/wicd-curses.py 2015-02-24 23:41:01 +0000
5@@ -532,7 +532,10 @@
6 def get_selected_profile(self):
7 """Get the selected wired profile"""
8 loc = self.get_focus()[1]
9- return self.theList[loc]
10+ if len(self.theList) > loc:
11+ return self.theList[loc]
12+ else:
13+ return self.theList[-1]
14
15
16 class AdHocDialog(Dialog2):