1: /* $Header$ */ 2: 3: /* 4: * Author: Peter J. Nicklin 5: */ 6: 7: /* 8: * ppathhead() removes tail of project pathname and returns pathname. 9: * The tail is defined as that part of the pathname after the last separator. 10: */ 11: #include "null.h" 12: #include "path.h" 13: 14: char * 15: ppathhead(ppathname) 16: register char *ppathname; 17: { 18: register char *ls; /* last separator character */ 19: register char *p; /* project pathname pointer */ 20: 21: ls = NULL; 22: for (p = ppathname; *p != '\0'; p++) 23: if (*p == _PPSC) 24: ls = p; 25: if (ls != NULL) *ls = '\0'; 26: return(ppathname); 27: }