How to interrupt a fread call?
问题 I have the following situation: There is a thread that reads from a device with a fread call. This call is blocking as long as there is no data send from the device. When I stop this thread it remains hanging inside this thread. Now I found the following inside the man page of fread: ERRORS On all systems that conform to the Single UNIX Specification, the fread() function sets errno as listed for the following conditions: [EINTR] The read operation was terminated due to the receipt of a