small fix for issue #12

default_encoding was not always set, generating an undefined variable
warning