ReadFile expects DWORD* not unsigned long *
fixed compilation error
using tolower from global scope, to make sure we use it from c library