Try:
char arr[] = &cDriveletter;
Or
char arr[2];
arr[0] = cDriveLetter;
arr[1] = '\0';
And then pass
arr
to your function.
The latter is safer as it allocates the space for the char and a trailing null to terminate a "C-style" string. The former will work if
getfil
only uses the first character of the array passed to it.