update cipher.cpp: remove redundant output file close statement