Bug fix WinApi when func has no parameters