Originally Posted by
Adak
I liked the while(1) loop better, myself, but I saw the for loop there, and thought his idea should be followed. HH, if you have no preferences, why not remove the for loop, and put the while(1) loop into it's place.
Note that the if 0 line of code, is gone, and should stay gone.
We do have a problem with the fread() line. IMO "t" should not be in that line. You have a buffer to put the data into, and the data has to fit into that buffer. T has nothing to do with that.
I suspect that T is not even needed, but Matsp is the expert.
I see it as "You're going to take a bunch of apples & put them in a box of 1024, and stack them in a warehouse". You don't care how many apples there are in the truck, because you have to take them all, anyway."