Connections now close properly upon receiving 404 errors