br...@apache.org wrote on Fri, Dec 14, 2018 at 14:55:43 -0000: > Add new dirent, relpath and URI canonicalization functions that > check and report canonicalization failures.
LGTM, nits below: > @@ -473,6 +476,30 @@ const char * > +/** > + * Return a new @a *cannonical_dirent like @a dirent, but transformed such Typo "cannonical". > + * Similar to svn_dirent_canonicalize() (which see), but returns an error > + * if the @a dirent can not be canonicalized or of the result does not pass > + * the svn_dirent_is_canonical() test. Suggest to add a pointer from svn_dirent_canonicalize()'s docstring to this function. > + * If the function fails and @a non_canonical_result is not @c NULL, the > + * result of the failed canonicalization attempt will be returned in > + * @a *non_canonical_result. > + * > + * Allocates the results in @a result_pool. Uses @a scratch_pool for > + * temporary allocations. > + * > + * @since New in 1.12. > + */ > +svn_error_t * > +svn_dirent_canonicalize_safe(const char **canonical_dirent, > + const char **non_canonical_result, > + const char *dirent, > + apr_pool_t *result_pool, > + apr_pool_t *scratch_pool);