Don't use new 'char' key word for SM 1.7

Replaced all 'char' variable names to 'chr'