Segfault in svn when not allowed to read config (v1.8.10)
Hi all, Today I ran into the following issue: when running svn help/status/etc with a user that is not allowed to read it's config directory the command exits with a segfault. Of course this is a bit of a corner case but it's probably easy to fix. As requested by the "reporting issues" page I will first run this by the users lists. The analysis: svn --version svn, version 1.8.10 (r1615264) compiled Aug 14 2014, 16:55:24 on x86_64-unknown-linux-gnu (gdb) run Starting program: /usr/local/bin/svn status [Thread debugging using libthread_db enabled] svn: warning: W13: Can't open file '/home/user/.subversion/servers': Permission denied Program received signal SIGSEGV, Segmentation fault. find_entry (ht=0x0, key=0x420d17, klen=-1, val=0x0) at tables/apr_hash.c:293 293 tables/apr_hash.c: No such file or directory. in tables/apr_hash.c (gdb) bt #0 find_entry (ht=0x0, key=0x420d17, klen=-1, val=0x0) at tables/apr_hash.c:293 #1 0x7562956b in apr_hash_get (ht=0x0, key=0x420d17, klen=-1) at tables/apr_hash.c:367 #2 0x0041d1f7 in sub_main (argc=, argv=, pool=0x64c2b8) at subversion/svn/svn.c:2583 Looking at the code in svn.c the following seems to happen: Around line 2514 cfg_hash is set to NULL when the directory is inaccessible: /* Fallback to default config if the config directory isn't readable or is not a directory. */ if (APR_STATUS_IS_EACCES(err->apr_err) || SVN__APR_STATUS_IS_ENOTDIR(err->apr_err)) { svn_handle_warning2(stderr, err, "svn: "); svn_error_clear(err); cfg_hash = NULL; } Then on line 2583 the cfg_hash is accessed resulting in the segfault: cfg_config = svn_hash_gets(cfg_hash, SVN_CONFIG_CATEGORY_CONFIG); Should I proceed with creating an issue? Is it safe to just remove the cfg_hash = NULL line? It looks like the config is wiped rather than reset to it's defaults. Regards, Bart
IndexError: list index out of range [serf-1.3.8]
Hi , I am getting following error while installing serf on my solaris machine . Please suggest -bash-3.2# scons install scons: Reading SConscript files ... File "/export/home/mabbas/svn1.8.10/serf-1.3.8/SConstruct", line 275: lib_shared = env.SharedLibrary(LIBNAME, SOURCES + SHARED_SOURCES) File "/usr/local/python/lib/scons-2.3.4/SCons/Environment.py", line 260: return MethodWrapper.__call__(self, target, source, *args, **kw) File "/usr/local/python/lib/scons-2.3.4/SCons/Environment.py", line 224: return self.method(*nargs, **kwargs) File "/usr/local/python/lib/scons-2.3.4/SCons/Builder.py", line 633: return self._execute(env, target, source, OverrideWarner(kw), ekw) File "/usr/local/python/lib/scons-2.3.4/SCons/Builder.py", line 554: tlist, slist = self._create_nodes(env, target, source) File "/usr/local/python/lib/scons-2.3.4/SCons/Builder.py", line 518: target, source = self.emitter(target=tlist, source=slist, env=env) File "/usr/local/python/lib/scons-2.3.4/SCons/Builder.py", line 344: target, source = e(target, source, env) File "/usr/local/python/lib/scons-2.3.4/SCons/Tool/link.py", line 86: target[0].name = version_names[0] -bash-3.2# cat /etc/release Oracle Solaris 10 8/11 s10s_u10wos_17b SPARC Copyright (c) 1983, 2011, Oracle and/or its affiliates. All rights reserved. Assembled 23 August 2011 -bash-3.2# -bash-3.2# -bash-3.2# python -V Python 2.7.7 -bash-3.2# scons --version SCons by Steven Knight et al.: script: v2.3.4, 2014/09/27 12:51:43, by garyo on lubuntu engine: v2.3.4, 2014/09/27 12:51:43, by garyo on lubuntu engine path: ['/usr/local/python/lib/scons-2.3.4/SCons'] Copyright (c) 2001 - 2014 The SCons Foundation Regards Mohsin Abbas -- View this message in context: http://subversion.1072662.n5.nabble.com/IndexError-list-index-out-of-range-serf-1-3-8-tp190985.html Sent from the Subversion Users mailing list archive at Nabble.com.