From 0b885650fe63d7679e4fa51c06ae9511dac7af42 Mon Sep 17 00:00:00 2001 From: Chris Down Date: Tue, 20 Feb 2018 10:38:48 +0000 Subject: [PATCH] Revert "Remove partial clip dedupe support" This reverts commit caa009b222e6b859c86de1b44409f9a013f0ae10. --- clipmenud | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/clipmenud b/clipmenud index f273aa2..684e776 100755 --- a/clipmenud +++ b/clipmenud @@ -160,6 +160,15 @@ while true; do continue fi + # If we were in the middle of doing a selection when the previous poll + # ran, then we may have got a partial clip. + possible_partial=${last_data[$selection]} + if [[ $possible_partial && $data == "$possible_partial"* ]]; then + debug "$possible_partial is a possible partial of $data" + debug "Removing ${last_filename[$selection]}" + rm -- "${last_filename[$selection]}" + fi + last_data[$selection]=$data first_line=$(get_first_line "$data")