Added a few "finally" flow controllers to close the streams