env: Adjust the get_char() method to return an int