diff --git a/bluefish.spec b/bluefish.spec index 86c5d4a..349c212 100644 --- a/bluefish.spec +++ b/bluefish.spec @@ -1,6 +1,6 @@ %global pkgver 2.0.2 #global prerel rc1 -%global rpmrel 4 +%global rpmrel 5 Name: bluefish Version: %{pkgver} @@ -11,6 +11,7 @@ License: GPLv3+ URL: http://bluefish.openoffice.nl/ Source0: http://www.bennewitz.com/bluefish/stable/source/bluefish-%{version}%{?prerel:-%{prerel}}.tar.bz2 Patch0: fedora_bug_653299.patch +Patch1: fedora_bug_663014.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: desktop-file-utils BuildRequires: enchant-devel >= 1.4.2 @@ -70,6 +71,10 @@ Files common to every architecture version of %{name}. # (upstream patch) %patch0 -p0 +# Fix crash in autosave (#663014) +# (upstream patch) +%patch1 -p0 + %build %configure --disable-dependency-tracking \ --disable-static \ @@ -146,6 +151,9 @@ fi %{_mandir}/man1/%{name}.1* %changelog +* Wed Dec 15 2010 Paul Howarth - 2.0.2-5 +- Fix crash in autosave (#663014) + * Thu Nov 18 2010 Paul Howarth - 2.0.2-4 - Fix crash when removing files/projects from recently-used lists (#653299) diff --git a/fedora_bug_663014.patch b/fedora_bug_663014.patch new file mode 100644 index 0000000..08b7ee2 --- /dev/null +++ b/fedora_bug_663014.patch @@ -0,0 +1,35 @@ +Index: src/file_autosave.c +=================================================================== +--- src/file_autosave.c (revision 6096) ++++ src/file_autosave.c (working copy) +@@ -1,7 +1,7 @@ + /* Bluefish HTML Editor + * file_autosave.c - autosave + * +- * Copyright (C) 2009 Olivier Sessink ++ * Copyright (C) 2009-2010 Olivier Sessink + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by +@@ -227,8 +227,11 @@ + doc->autosave_uri = create_autosave_path(doc, hasht); + g_hash_table_insert(hasht, g_file_get_path(doc->autosave_uri), GINT_TO_POINTER(1)); + } ++ + buffer = refcpointer_new(doc_get_chars(doc, 0, -1)); +- doc->autosave_action = file_checkNsave_uri_async(doc->autosave_uri, NULL, buffer, strlen(buffer->data), FALSE, FALSE, (CheckNsaveAsyncCallback)autosave_complete_lcb, doc); ++ if (buffer->data) { ++ doc->autosave_action = file_checkNsave_uri_async(doc->autosave_uri, NULL, buffer, strlen(buffer->data), FALSE, FALSE, (CheckNsaveAsyncCallback)autosave_complete_lcb, doc); ++ } + refcpointer_unref(buffer); + } + +@@ -268,7 +271,7 @@ + while (tmplist) { + gchar **arr = (gchar **)tmplist->data; + GFile *recover_uri; +- if (count_array(arr)!=3) { ++ if (g_strv_length(arr)!=3) { + tmplist = g_list_next(tmplist); + continue; + }