Compile fixes for 10.9

(cherry picked from commit b17b075361ceb9cf31da36db32731881f9fb186e)