Gee, that sounds like a routine you could write yourself!
I mean, golly gosh! since the string you have is just an array of characters, at the very least you could smatter together a routine like this (not how I would do it)--
Code:
int main(void);
void getdrivestring(char*,char*);
int main(void)
{
char driveString[4]; /* just enough to hold device letter */
char path[] = "C:/Windows/System";
getdrivestring(path,driveString); /* parse out the letter */
return(0);
}
void getdrivestring(char *a,char *b)
{
int i;
for(i=0;i<3;i++)
b[i] = a[i]; /* copy first 3 letters */
b[3] = 0x00; /* length terminating byte */
}
seems rather brute-force, yet it would do the trick, eh?