Mutex needs `require 'thread'` in Ruby <1.9

Trying to load the library on a Ruby 1.8 results in an error about an undefined constant `Mutex`

This is solved by requiring `thread`.

I would build a test case for this, but it is a straightforward change and unfortunately your testing suite uses `shoulda` which doesn't work on Ruby 1.8.