I checked and the code is Apache2 Note: Licenses are only required to use copyrightable work without fair use, so you can use this as reference freely without risking you PR to fall under the Apache2 license as using it as a reference has already been considered fair use by law many times.
Please don't post misleading information, that code is clearly from the Microsoft SDK, it's not Apache2.