Fix wrong environment variable name

LC_CTYPES ->
LC_CTYPE

GitHub: mutoh/locale#5

Patch by Hleb Valoshka. Thanks!!!
Use the default charset when the first tag doesn't have charset

Debian: #520181
GitHub: mutoh/locale#5

Reported by Hleb Valoshka. Thanks!!!