mitchellh/vagrant — pull request #911 by squarelover (2012-05-01 21:09:27+00:00)
Title: Don't raise an error if keyfile permissions are modified successfully

In the `Vagrant::SSH#check_key_permissions` method, it would set the correct file permissions if they were incorrect. Then it checked again to see if the change actually was applied. There was a bug in the code that didn't update the `stat` object, so therefore it will always check against the old permissions, not the new. This would cause an error to be raised which would halt execution on the first run.

This patch fixes the error, and has an elementary unit test for this bug.