Cleanup FileStorage

A set of cleanup changes, mainly to convince myself that it is thread safe and sufficiently robust...
CHECK_EQ is better, because it will dump the value of ```status``` (both the code and the message).