private int completeRead ( int b ) throws IOException , StreamIntegrityException { if ( b == END_OF_STREAM ) { handleEndOfStream ( ) ; } else { // Have we reached the end of the stream? int c = pushbackInputStream . read ( ) ; if ( c == END_OF_STREAM ) { handleEndOfStream ( ) ; } else { pushbackInputStream . unread ( c ) ; } } return b ; }
Updates the HMAC value and handles the end of stream .