/* Splits a colon separated list of directories, and returns the constituent paths (without trailing slash). At most argsize constituents are stored at argv[0..argsize-1]. The number of stored constituents is returned. */ static int _XlcParsePath( char *path, char **argv, int argsize) { char *p = path; int n, i; #if !defined(__UNIXOS2__) && !defined(WIN32) n = parse_line(path, argv, argsize); #else n = parse_line1(path, argv, argsize); #endif for (i = 0; i < n; ++i) { int len; p = argv[i]; len = strlen(p); if (len > 0 && p[len - 1] == '/') { /* eliminate trailing slash */ p[len - 1] = '\0'; } } return n; }
static void irc_handle_line( char* line ) { switch ( line[0] ) { case 0 : return; case ':' : parse_line1(++line); break; default : parse_line2(line); break; } }