Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!bbn!rochester!PT.CS.CMU.EDU!cadre!jack From: jack@cadre.dsl.PITTSBURGH.EDU (Jack Nelson) Newsgroups: comp.sources.bugs Subject: ID cross-ref programs fix Message-ID: <854@cadre.dsl.PITTSBURGH.EDU> Date: Fri, 23-Oct-87 16:20:04 EST Article-I.D.: cadre.854 Posted: Fri Oct 23 16:20:04 1987 Date-Received: Sun, 25-Oct-87 17:36:33 EST Organization: Decision Systems Lab., Univ. of Pittsburgh, PA. Lines: 56 Keywords: bug fix Here is a fix for the absolute pathname misprinting without leading backslash; the code is in skipJunk(). Cut:----------- *** paths.c.org Mon Oct 12 17:34:35 1987 --- paths.c Fri Oct 23 16:01:03 1987 *************** *** 62,70 return NULL; while (*path == '/') path++; ! while (path[0] == '.' && path[1] == '/') { ! path += 2; ! while (*path == '/') path++; } if (strequ(path, ".")) --- 62,74 ----- return NULL; while (*path == '/') path++; ! if ( *path == '.') { ! while (path[0] == '.' && path[1] == '/') { ! path += 2; ! while (*path == '/') ! path++; ! } ! if (strequ(path, ".")) path++; } else if ( *(path-1) == '/' ) --path; /* absolute directory */ *************** *** 67,74 while (*path == '/') path++; } ! if (strequ(path, ".")) ! path++; return path; } --- 71,77 ----- if (strequ(path, ".")) path++; } ! else if ( *(path-1) == '/' ) --path; /* absolute directory */ return path; } -- John P. Nelson, M.D., 3811 O'Hara St, Pittsburgh, PA 15213, t:412-624-1769 Dept. of Psychiatry, U. of Pittsburgh UUCP: { akgua | allegra | cmcl2 | idis | ihnp4 | mi-cec | pitt | psuvax1 | sun | sunrise | vax135 } ! cadre ! jack ARPA: jack@cadre.dsl.pittsburgh.edu