question: public int available ( ) throws IOException { int bytesAvailable = in . available ( ) ; if ( bytesAvailable > bytesLeft ) bytesAvailable = bytesLeft ; return bytesAvailable ; }
target:  Returns the number of bytes that can be read with blocking. Make sure that this does not exceed the number of bytes remaining in the proper content of the message.