Jim Meyering <[EMAIL PROTECTED]> writes: > @@ -78,10 +79,49 @@ path_concat (char const *dir, char const > p += needs_separator; > > if (base_in_result) > - *base_in_result = p; > + *base_in_result = p - IS_ABSOLUTE_FILE_NAME (abase); > > p = mempcpy (p, base, baselen); > *p = '\0'; > > + assert (!base_in_result > + || strcmp (*base_in_result, abase) == 0); > +
I think this assertion will trigger if abase starts with multiple slashes, which are all stripped by longest_relative_suffix. Andreas. -- Andreas Schwab, SuSE Labs, [EMAIL PROTECTED] SuSE Linux Products GmbH, Maxfeldstra�e 5, 90409 N�rnberg, Germany Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different." _______________________________________________ Bug-coreutils mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-coreutils
