Check CreateFileW() return value correctly (#670)
Check CreateFileW() return value correctly (#670)

Summary:
`CreateFileW()` returns `INVALID_HANDLE_VALUE` if the handle is invalid, so
this piece of code wouldn't correct handle a failure here.  Switch the code to
use the `FileDescriptor` class to make this less error prone.

Pull Request resolved: https://github.com/facebook/watchman/pull/670

Reviewed By: simpkins

Differential Revision: D13758292

Pulled By: wez

fbshipit-source-id: 94a8abf3acfa6df52caa296adf79c595e930c132

nodakai/watchman,nodakai/watchman,wez/watchman,wez/watchman,wez/watchman,nodakai/watchman,facebook/watchman,facebook/watchman,facebook/watchman,wez/watchman,nodakai/watchman,nodakai/watchman,wez/watchman,facebook/watchman,wez/watchman,wez/watchman,nodakai/watchman,facebook/watchman,wez/watchman,wez/watchman,nodakai/watchman,facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman,nodakai/watchman,nodakai/watchman