Flushing output
bug fixing.