10 May
2013
10 May
'13
7:11 p.m.
[Matt Weber]
That takes a 64-bit handle, but we have a 32-bit handle that we got back from _findfirst. That's the problem -- the handle returned from _findfirst (_findfirst64i32) is actually 64-bit.
_findfirst() is documented[1] as returning intptr_t, so that's what you should be declaring your variable as. That should work on both x86 and x64. STL [1] http://msdn.microsoft.com/en-us/library/zyzxfzac.aspx