diff --git a/src/Widgets/FindBar.cs b/src/Widgets/FindBar.cs
index c1b6cd3..70e5671 100644
--- a/src/Widgets/FindBar.cs
+++ b/src/Widgets/FindBar.cs
@@ -114,6 +114,8 @@ namespace FSpot.Widgets {
 		private void HandleEntryTextDeleted (object sender, TextDeletedArgs args)
 		{
 			int length = args.EndPos - args.StartPos;
+			if (length < 0)
+				return;
 			//Log.Debug ("start {0} end {1} len {2} last {3}", args.StartPos, args.EndPos, length, last_entry_text);
 			string txt = last_entry_text.Substring (args.StartPos, length);
 
