summaryrefslogtreecommitdiff
path: root/src/gtkext
diff options
context:
space:
mode:
Diffstat (limited to 'src/gtkext')
-rw-r--r--src/gtkext/hexdisplay.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gtkext/hexdisplay.c b/src/gtkext/hexdisplay.c
index ea662ae..49da03a 100644
--- a/src/gtkext/hexdisplay.c
+++ b/src/gtkext/hexdisplay.c
@@ -324,6 +324,8 @@ static void gtk_hex_display_populate_cache(GtkHexDisplay *display)
/* Adaptation du tampon interne */
+ g_buffer_cache_wlock(display->cache);
+
count = g_buffer_cache_count_lines(display->cache);
if (needed < count)
@@ -332,6 +334,8 @@ static void gtk_hex_display_populate_cache(GtkHexDisplay *display)
else if (needed > count)
g_buffer_cache_extend_with(display->cache, needed, G_LINE_GENERATOR(display->generator));
+ g_buffer_cache_wunlock(display->cache);
+
if (needed != count)
gtk_widget_queue_resize(GTK_WIDGET(display));