Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/shell/ev-jobs.c
diff options
context:
space:
mode:
authorNickolay V. Shmyrev <nshmyrev@src.gnome.org>2006-05-29 15:35:29 (GMT)
committer Nickolay V. Shmyrev <nshmyrev@src.gnome.org>2006-05-29 15:35:29 (GMT)
commit363996497c9b439597d46f002e995055e368d7a8 (patch)
tree4533513ddf62f62927ffbb7e90f60346da801b6e /shell/ev-jobs.c
parent225676bbda62378f9ff79712a0aa3d2d67a87714 (diff)
Don't crash on reload. Fix for the bug #343167.
* shell/ev-jobs.c: (ev_job_xfer_dispose), (ev_job_xfer_new): * shell/ev-jobs.h: * shell/ev-window.c: (ev_window_xfer_job_cb), (ev_window_open_uri), (ev_window_cmd_view_reload), (ev_window_init): Don't crash on reload. Fix for the bug #343167.
Diffstat (limited to 'shell/ev-jobs.c')
-rw-r--r--shell/ev-jobs.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/shell/ev-jobs.c b/shell/ev-jobs.c
index 8bd3d45..e9f29eb 100644
--- a/shell/ev-jobs.c
+++ b/shell/ev-jobs.c
@@ -389,6 +389,11 @@ ev_job_xfer_dispose (GObject *object)
job->error = NULL;
}
+ if (job->dest) {
+ g_object_unref (job->dest);
+ job->dest = NULL;
+ }
+
(* G_OBJECT_CLASS (ev_job_xfer_parent_class)->dispose) (object);
}
@@ -404,13 +409,15 @@ ev_job_xfer_class_init (EvJobXferClass *class)
EvJob *
-ev_job_xfer_new (const gchar *uri)
+ev_job_xfer_new (const gchar *uri, EvLinkDest *dest)
{
EvJobXfer *job;
job = g_object_new (EV_TYPE_JOB_XFER, NULL);
job->uri = g_strdup (uri);
+ if (dest)
+ job->dest = g_object_ref (dest);
return EV_JOB (job);
}