How do you extract the base path from pathname in C?
Are there any functions built into the C language or the C-Runtime L
There is no standard C99 function for doing this. POSIX has dirname(), but that won't help you much on Windows. It shouldn't be too hard for you to implement your own function, though; just search through the string, looking for the last occurrence of the directory separator, and discard anything after it.