Recompiling this demo I got an access violation alert closing the executable.