is this wrong?from msdn
Code:size_t fread( void *buffer, size_t size, size_t count, FILE *stream );
shouldnt it be
size_t count, then
size_t size,
This is a discussion on fread & msdn within the Windows Programming forums, part of the Platform Specific Boards category; from msdn Code: size_t fread( void *buffer, size_t size, size_t count, FILE *stream ); is this wrong? shouldnt it be ...
is this wrong?from msdn
Code:size_t fread( void *buffer, size_t size, size_t count, FILE *stream );
shouldnt it be
size_t count, then
size_t size,
Try to help all less knowledgeable than yourself, within
the limits provided by time, complexity and tolerance.
- Nor
You can use either way, as size*count will always be the same as count*size, but just remember that fread will always returns the number of full ITEMS read, not bytes. If I use fread however, I normally just use 1 as the size so I can see exactly how many bytes were read.
i needed to read the fine printbut just remember that fread will always returns the number of full ITEMS read, not bytes.
thx
Try to help all less knowledgeable than yourself, within
the limits provided by time, complexity and tolerance.
- Nor