Uploaded image for project: 'Subversion'
  1. Subversion
  2. SVN-4612

With Perl module SVN::Client, assertion failure due to non-canonical path

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.9.3
    • None
    • bindings_swig_perl
    • None

    Description

      Various functions assume that the path provided in argument is a canonical path. When the path is not canonical, this triggers an assertion failure in the library:

      svn_dirent_join: Assertion `svn_dirent_is_canonical(base, pool)' failed.

      While this may be acceptable for C programs, this is not in Perl, where one should get proper error reporting.

      Test case with info:

      #!/usr/bin/env perl
      
      use strict;
      use SVN::Client;
      
      my $svnc = SVN::Client->new;
      $svnc->info('.', undef, undef, sub { }, 0);
      

      The Perl module should make sure that the path is canonical before calling the corresponding svn library function (cannot this be automatically generated with swig if the code has some form of precondition that the path needs to be canonical?). It could either canonicalize the path so that the library call succeeds or immediately return an error if the path is not canonical. Alternatively, the svn library function could do path canonicalization itself.

      Attachments

        Activity

          People

            Unassigned Unassigned
            vinc17 Vincent Lefevre
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: