AddEndSlash
The FSF.AddEndSlash function appends a trailing backslash ('\') or a slash ('/') to a path if it is not there already.
int WINAPI AddEndSlash(
char *Path
);
Parameters
Path
A string containing the path to which you want to add a trailing slash or backslash.
Return value
On success return value is TRUE, otherwise return value is FALSE.
Remarks
- The string must be large enough to contain an additional character.
- If the path already contains some backslashes or slashes, the new one will be the same as the last one, otherwise '\'.
Example