Fixing char cast bug introduced in last commit.