Patch for https://github.com/Atmosphere/atmosphere/issues/1682
Merge pull request #1693 from agherardi/master

Patch for https://github.com/Atmosphere/atmosphere/issues/1682