Try FileUtils.chmod instead.  FileUtils is where the higher-level
stuff goes, I think.