Fixed some compiling errors. Refs #7788.