puppetlabs/puppet — pull request #2795 by joshcooper (2014-06-24 00:44:00+00:00)
Title: (PUP-1283) win32-security gem raises a different exception

Previously, puppet relied on win32-security version 0.1.4, which raises
Win32::Security::SID::Error when it fails to resolve a name into a SID.

However, FFI versions of win32-security raise SystemCallError instead,
which is a StandardError subclass. When trying to run the puppet agent
against newer versions of the library, puppet reports:

Uninitialized constant Win32::Security::SID::Error

This commit changes the rescue to capture standard errors instead.