aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--ChangeLog.ja5
-rw-r--r--src/imageview.c4
3 files changed, 14 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 179fa386..eaa85a70 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-06-27
+
+ * src/imageview.c: fixed a possible crash on the view change from
+ imageview to textview (thanks to NINOMIYA Yuuki).
+
2005-06-24
* src/ssl.c: show verify result as string.
diff --git a/ChangeLog.ja b/ChangeLog.ja
index 26462a54..decac54d 100644
--- a/ChangeLog.ja
+++ b/ChangeLog.ja
@@ -1,3 +1,8 @@
+2005-06-27
+
+ * src/imageview.c: イメージビューからテキストビューに切り替えるとき
+ にクラッシュする可能性があったのを修正(二之宮さん thanks)。
+
2005-06-24
* src/ssl.c: 検証結果を文字列として表示。
diff --git a/src/imageview.c b/src/imageview.c
index bbe14c9e..312794f7 100644
--- a/src/imageview.c
+++ b/src/imageview.c
@@ -89,6 +89,8 @@ void imageview_show_image(ImageView *imageview, MimeInfo *mimeinfo,
GError *error = NULL;
g_return_if_fail(imageview != NULL);
+ g_return_if_fail(imageview->scrolledwin != NULL);
+ g_return_if_fail(imageview->scrolledwin->parent != NULL);
if (file) {
imageview_clear(imageview);
@@ -242,6 +244,8 @@ static void size_allocate_cb(GtkWidget *widget,GtkAllocation *allocation,
imageview->resizing = FALSE;
return;
}
+ if (!imageview->scrolledwin->parent)
+ return;
imageview_show_image(imageview, NULL, NULL, TRUE);
imageview->resizing = TRUE;
}