src/stdlib/path.c
/*===============================================
 * is_absolute_path -- Is this an absolute path ?
 *  handle WIN32 characters, and ~ homedir references
 *=============================================*/
- Is this an absolute path .
handle WIN32 characters, and ~ homedir references
- Is this an absolute path . handle WIN32 characters and ~ homedir references
BOOLEAN
is_absolute_path (CNSTRING dir)
{
	if (is_dir_sep(dir[0])) return TRUE;
	if (dir[0] == '.') return TRUE;
	if (dir[0] == '~') return TRUE;
#ifdef WIN32
	if (dir[0] && dir[1]==':' && isasciiletter(dir[0])) {
		return TRUE;
	}
#endif
	return FALSE;
}
BOOLEAN is_absolute_path ( CNSTRING dir ) { if ( is_dir_sep ( dir [ 0 ] ) ) return TRUE ; if ( dir [ 0 ] == ' ' ) return TRUE ; if ( dir [ 0 ] == ' ' ) return TRUE ; #ifdef WIN32 if ( dir [ 0 ] && dir [ 1 ] == ' ' && isasciiletter ( dir [ 0 ] ) ) { return TRUE ; } #endif return FALSE ; }
is_absolute_path -- Is this an absolute path ?
is_absolute_path -- Is this an absolute path ?
/* if it starts with a slash, it's absolute */ /* if it starts with a dot, it's relative, but not relative
	to search path, only to current directory -- as in shell logic 
	so we say it is absolute */ /* if it starts with ~, it is a reference to an absolute home dir */ /* if it starts with a drive letter, it's absolute */