bail out when terminal reports zero width (e.g. under emacs shell)