Fix build error and warnings in Fedora 18.

BUG=None
TEST=Manual

Committed: 47d90f5

Review URL: https://codereview.appspot.com/7531047