531 |
* stores them into the buffer pointed to by s. Reading stops after |
* stores them into the buffer pointed to by s. Reading stops after |
532 |
* an EOF or a newline. If a newline is read, it is stored into the |
* an EOF or a newline. If a newline is read, it is stored into the |
533 |
* buffer. A '\0' is stored after the last character in the buffer. |
* buffer. A '\0' is stored after the last character in the buffer. |
534 |
* @unnecessary S A Socket_T object |
* @param S A Socket_T object |
535 |
* @unnecessary s A character buffer to store the string in |
* @param s A character buffer to store the string in |
536 |
* @param size The size of the string buffer, s |
* @param size The size of the string buffer, s |
537 |
* @return s on success, and NULL on error or when end of file occurs |
* @return s on success, and NULL on error or when end of file occurs |
538 |
* while no characters have been read. |
* while no characters have been read. |
564 |
/* |
/* |
565 |
* Fill the internal buffer. If an error occurs or if the read |
* Fill the internal buffer. If an error occurs or if the read |
566 |
* operation timed out -1 is returned. |
* operation timed out -1 is returned. |
567 |
* @param S An InputStream object |
* @param S A Socket object |
568 |
* @return TRUE (the length of data read) or -1 if an error occured |
* @return TRUE (the length of data read) or -1 if an error occured |
569 |
*/ |
*/ |
570 |
static int fill(Socket_T S) { |
static int fill(Socket_T S) { |