fix bug where terminal would randomly become garbled binary crap