lanoxx/tilda — pull request #44 by Ed-von-Schleck (2014-03-07 13:14:58+00:00)
Title: Cleaned up finding of free lock instance

The previous algorithm had a O(n**2) list creation and O(n**2) search
for the lowest not-taken lock instance. One could argue that
the numbers involved are small enough to not make a difference, but
this version has a O(n logn) list creation and O(n) search without being
more complicated, so it might be worth it.