fixed pipeline() algorithm: there was some unprocessed items in pipes sometime