* New upstream version.
* Security fixes:
- Add check to XPM reader to prevent integer overflow for specially crafted
number of colors (CVE-2005-3186) (Closes: #339431).
- Fix endless loop with specially crafted number of colors (CVE-2005-2975).
* debian/patches/001_fs_documents.patch:
- updated.
* debian/rules:
- fix confusing cp usage.
[ Loic Minier ]
* Drop xlibs-dev deps and build-deps.
[debian/control, debian/control.in]
-- Sebastien Bacher <seb128@debian.org> Wed, 16 Nov 2005 11:54:11 +0100
74 lines
1.8 KiB
Diff
74 lines
1.8 KiB
Diff
diff -Nur gtk+-2.8.7.orig/gtk/gtkfilechooserdefault.c gtk+-2.8.7/gtk/gtkfilechooserdefault.c
|
|
--- gtk+-2.8.7.orig/gtk/gtkfilechooserdefault.c 2005-11-11 20:50:21.000000000 +0100
|
|
+++ gtk+-2.8.7/gtk/gtkfilechooserdefault.c 2005-11-16 11:59:33.000000000 +0100
|
|
@@ -222,6 +222,7 @@
|
|
|
|
GtkTooltips *tooltips;
|
|
|
|
+ gboolean has_documents;
|
|
gboolean has_home;
|
|
gboolean has_desktop;
|
|
|
|
@@ -343,6 +344,7 @@
|
|
|
|
/* Interesting places in the shortcuts bar */
|
|
typedef enum {
|
|
+ SHORTCUTS_DOCUMENTS,
|
|
SHORTCUTS_HOME,
|
|
SHORTCUTS_DESKTOP,
|
|
SHORTCUTS_VOLUMES,
|
|
@@ -1476,6 +1478,33 @@
|
|
profile_end ("end", NULL);
|
|
}
|
|
|
|
+
|
|
+/* Appends the ~/Documents directory to the shortcuts model */
|
|
+static void
|
|
+shortcuts_append_documents (GtkFileChooserDefault *impl)
|
|
+{
|
|
+ char *name;
|
|
+ GtkFilePath *path;
|
|
+
|
|
+ name = g_build_filename (g_get_home_dir (), "Documents", NULL);
|
|
+ path = gtk_file_system_filename_to_path (impl->file_system, name);
|
|
+ g_free (name);
|
|
+
|
|
+ impl->has_documents = shortcuts_insert_path (impl, -1, FALSE, NULL, path, _("Documents"), FALSE, NULL);
|
|
+ /* We do not actually pop up an error dialog if there is no document directory
|
|
+ * because some people may really not want to have one.
|
|
+ */
|
|
+
|
|
+ gtk_file_path_free (path);
|
|
+}
|
|
+
|
|
+
|
|
+
|
|
+
|
|
+
|
|
+
|
|
+
|
|
+
|
|
/* Appends a list of GtkFilePath to the shortcuts model; returns how many were inserted */
|
|
static int
|
|
shortcuts_append_paths (GtkFileChooserDefault *impl,
|
|
@@ -1527,6 +1556,11 @@
|
|
|
|
n = 0;
|
|
|
|
+ if (where == SHORTCUTS_DOCUMENTS)
|
|
+ goto out;
|
|
+
|
|
+ n += impl->has_documents ? 1 : 0;
|
|
+
|
|
if (where == SHORTCUTS_HOME)
|
|
goto out;
|
|
|
|
@@ -1875,6 +1909,7 @@
|
|
|
|
if (impl->file_system)
|
|
{
|
|
+ shortcuts_append_documents (impl);
|
|
shortcuts_append_home (impl);
|
|
shortcuts_append_desktop (impl);
|
|
shortcuts_add_volumes (impl);
|