Fix input stream buffer behaviour in order to detect end of sequence and
add support to lock multiple sequence display