|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #57701 svn_ls calling generates Assertion is_canonical failure
Submitted: 2007-06-13 05:10 UTC Modified: 2007-06-13 05:18 UTC
From: ciprian dot amariei at gmail dot com Assigned:
Status: Closed Package: svn (PECL)
PHP Version: 5.2.1 OS: Ubuntu Fiesty
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: ciprian dot amariei at gmail dot com
New email:
PHP Version: OS:


 [2007-06-13 05:10 UTC] ciprian dot amariei at gmail dot com
svn_ls does not return anything and generates an error for some servers.

Reproduce code:
$ar = svn_ls("",-1);

Expected result:
array with ls content

Actual result:
apache2: /build/buildd/subversion-1.4.3dfsg1/subversion/libsvn_subr/path.c:343: svn_path_remove_component: Assertion `is_canonical(path->data, path->len)' failed.
[Wed Jun 13 04:57:56 2007] [notice] child pid 7410 exit signal Aborted (6)


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2007-06-13 05:18 UTC] ciprian dot amariei at gmail dot com
done some more research on this and it turns out to be a stupid problem that comes from subversion libraries:

from path.c:
#ifndef NDEBUG
static svn_boolean_t
is_canonical (const char *path,
               apr_size_t len)
   return (! SVN_PATH_IS_PLATFORM_EMPTY (path, len)
           && (len <= 1 || path[len-1] != '/'));

The problem was the trailing slash. ;) Now it works just fine.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Mon Dec 06 03:03:34 2021 UTC