From 12d0732136bdebf2884b118caed7e544a30577ca Mon Sep 17 00:00:00 2001 From: Jan Klepek Date: Feb 28 2014 17:51:11 +0000 Subject: patch for issue with missing ~/.byobu/status leading to crash in byobu-config --- diff --git a/byobu-5.73-config_except.patch b/byobu-5.73-config_except.patch new file mode 100644 index 0000000..fac5b0a --- /dev/null +++ b/byobu-5.73-config_except.patch @@ -0,0 +1,21 @@ +--- usr/lib/byobu/include/config.py.old 2014-02-28 18:10:06.262946167 +0100 ++++ usr/lib/byobu/include/config.py 2014-02-28 18:30:45.862109401 +0100 +@@ -212,10 +212,16 @@ + status[i[1]] = i[0] + for key in ["tmux_left", "tmux_right", "screen_upper_left", "screen_upper_right", "screen_lower_left", "screen_lower_right"]: + if key.startswith(BYOBU_BACKEND): +- f = open(path, "r") ++ try: ++ f = open(path, "r") ++ except: ++ f = open(SHARE + '/status/status', "r") + lines = f.readlines() + f.close() +- f = open(path, "w") ++ try: ++ f = open(path, "w") ++ except: ++ f = open(path, "a+") + for l in lines: + if l.startswith("%s=" % key): + val = genstatusstring(key, status) diff --git a/byobu.spec b/byobu.spec index 48b8694..d5df46c 100644 --- a/byobu.spec +++ b/byobu.spec @@ -6,7 +6,7 @@ Name: byobu Version: 5.73 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Light-weight, configurable window manager built upon GNU screen Group: Applications/System @@ -23,6 +23,8 @@ Patch1: byobu-5.73-bash.patch Patch2: byobu-5.73-tmux_date.patch # patch for multiple sourcing, https://bugs.launchpad.net/byobu/+bug/1273685 Patch3: byobu-5.73-tmuxrc_source.patch +# patch for crashing byobu-config, https://bugs.launchpad.net/byobu/+bug/1286249 +Patch4: byobu-5.73-config_except.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch %if 0%{?rhel}%{?fedora} > 5 @@ -60,6 +62,7 @@ done %patch1 %patch2 %patch3 +%patch4 # fix path for correct directory in /usr/share sed -i "s#DOC = BYOBU_PREFIX + '/share/doc/' + PKG#DOC='%{_pkgdocdir}'#g" usr/lib/byobu/include/config.py @@ -136,6 +139,9 @@ fi %config(noreplace) %{_sysconfdir}/%{name}/* %changelog +* Fri Feb 28 2014 Jan Klepek - 5.73-4 +- patch for issue with missing ~/.byobu/status leading to crash in byobu-config + * Thu Feb 27 2014 Jan Klepek - 5.73-3 - various upstream patches