Don't terminate streams that were already terminated
Don't terminate streams that were already terminated

This and the issues in the last two commits were reported
by leo2007 on IRC.

CrankWheel/cowboy,turtleDeng/cowboy,ninenines/cowboy,K2InformaticsGmbH/cowboy,bsmr-erlang/cowboy,kivra/cowboy,hairyhum/cowboy