[evince] [shell] Fix loading of remote files
- From: Carlos Garcia Campos <carlosgc src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [evince] [shell] Fix loading of remote files
- Date: Fri, 6 Nov 2009 12:40:27 +0000 (UTC)
commit c93a4600cd131defae675a19604990cb4dc32cb3
Author: Carlos Garcia Campos <carlosgc gnome org>
Date: Fri Nov 6 13:37:07 2009 +0100
[shell] Fix loading of remote files
It was broken by the temp file handling rework
shell/ev-window.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/shell/ev-window.c b/shell/ev-window.c
index 6f98711..54be8b7 100644
--- a/shell/ev-window.c
+++ b/shell/ev-window.c
@@ -1718,7 +1718,7 @@ ev_window_load_file_remote (EvWindow *ev_window,
* it helps to resolve some mime types, say cbz.
*/
base_name = g_file_get_basename (source_file);
- template = g_build_filename ("document.XXXXXX-%s", base_name, NULL);
+ template = g_strdup_printf ("document.XXXXXX-%s", base_name);
g_free (base_name);
tmp_file = ev_mkstemp_file (template, &err);
@@ -1740,7 +1740,8 @@ ev_window_load_file_remote (EvWindow *ev_window,
target_file = g_file_new_for_uri (ev_window->priv->local_uri);
g_file_copy_async (source_file, target_file,
- 0, G_PRIORITY_DEFAULT,
+ G_FILE_COPY_OVERWRITE,
+ G_PRIORITY_DEFAULT,
ev_window->priv->progress_cancellable,
(GFileProgressCallback)window_open_file_copy_progress_cb,
ev_window,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]