Minor fixes to make it compile again

Builds on OS X 10.8