#WinAPI does not return any data
7 messages · Page 1 of 1 (latest)
7 messages · Page 1 of 1 (latest)
If the function fails, the return value is zero and GetLastError returns the error code.
the slice you give it has size 0
it preallocates the capacity
but the size is still 0
the capacity says how many elements you can add to the vector without another allocation
the size says how many elements are actually in the vector
vec![0; 128]