[gnome-builder] editor-frame: fail fast on non-IdeBuffer
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] editor-frame: fail fast on non-IdeBuffer
- Date: Sun, 20 Sep 2015 11:39:52 +0000 (UTC)
commit 46820960c8e59058960e250e949cb111db922e34
Author: Christian Hergert <christian hergert me>
Date: Sun Sep 20 04:38:18 2015 -0700
editor-frame: fail fast on non-IdeBuffer
This should only happen during initiailization.
src/editor/gb-editor-frame.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/editor/gb-editor-frame.c b/src/editor/gb-editor-frame.c
index 067a039..ae1a3fc 100644
--- a/src/editor/gb-editor-frame.c
+++ b/src/editor/gb-editor-frame.c
@@ -62,6 +62,9 @@ gb_editor_frame_update_ruler (GbEditorFrame *self)
buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (self->source_view));
+ if (!IDE_IS_BUFFER (buffer))
+ return;
+
/* update line/column text */
if (self->show_ruler)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]