ioctl with FIONREAD as request

it returns size of bytes ready to read, but to store that size it requires pointer to int passed in va_args

when i want to malloc a memory using that size i need variable of type size_t which is 8 bytes on 64-bit system

why do this types mismatch? if ioctl returns size with FIONREAD request it should accept pointer to size_t variable in va_args

Add Comment