Fix race condition in `ThreadedHistory`.
The Lock in `ThreadedHistory` was not always properly released, and because of that, in situations where the user was pasting enormous amounts of text, the application could freeze at the point where lines were added to the history.
J
Jonathan Slenders committed
d5e58a811910627db8b6d9c1636ec30a4df1a850
Parent: e58bd7c