diff --git a/README.markdown b/README.markdown index 9866a83..1629287 100644 --- a/README.markdown +++ b/README.markdown @@ -171,11 +171,12 @@ For some advanced uses of pqiv, take a look at these resouces: Changelog --------- -pqiv 2.10.2 +pqiv 2.10.3 * Fix output of `montage_mode_shift_y_rows()` in key bindings * Update the info text when the background pattern is cycled * Prevent potential crashes in poppler backend for rapid image movements * Fix processing of dangling symlinks in the file buffer + * Removed possible deadlock in ImageMagick wand backend pqiv 2.10 * Enable cursor auto-hide by default diff --git a/backends/wand.c b/backends/wand.c index f6bce71..60fc111 100644 --- a/backends/wand.c +++ b/backends/wand.c @@ -139,12 +139,17 @@ BOSNode *file_type_wand_alloc(load_images_state_t state, file_t *file) {/*{{{*/ new_file->private = g_slice_new0(file_private_data_wand_t); ((file_private_data_wand_t *)new_file->private)->page_number = n + 1; + // Temporarily give up lock to do this: Otherwise we might see a deadlock + // if another thread holding the file tree's lock is waiting for the wand + // lock for another operation. + G_UNLOCK(magick_wand_global_lock); if(n == 0) { first_node = load_images_handle_parameter_add_file(state, new_file); } else { load_images_handle_parameter_add_file(state, new_file); } + G_LOCK(magick_wand_global_lock); } if(first_node) {