If you though Macs are safer, here something that will scare you. It has been found that Macs sold before middle of 2014 have a vulnerability which gets activated when the system goes into the sleep mode. While in Sleep mode, the underlying UEFI (Firmware interface code) gets unlocked, allowing external malware to take charge of your system BIOS and settings.
The only solution to this vulnerability would be to prevent your Mac from going into the sleep mode, and use Shutdown instead. This was discovered by researcher Pedro Vilaca, who specializes in Mac O/S security issues.
Apparently, Apple did know of this shortcoming in that sequence of Macs and did not patch the vulnerability for that set of devices.