It doesn't matter, the compiler will promote the var to an integer implicitly.
The problem is this line: STRING *read = " "; The STRING is actually a const char *, not a STRING *. Use str_create() to create a temporary string and str_remove() to clean it up afterwards.