Re: [PATCH] Make sure resolving a conflict with `svn_wc_conflict_choose_merged' can't break the workqueue by referencing a non-existing file

2022-04-22 Thread Sergey Raevskiy
t; On Thu, Apr 21, 2022 at 08:25:32PM +0300, Sergey Raevskiy wrote: > > I've noticed that in some cases a working copy can become inoperable > > after merge text conflict resolution with `svn_wc_conflict_choose_merged' > > option. > > > > The problem can occur in t

[PATCH] Make sure resolving a conflict with `svn_wc_conflict_choose_merged' can't break the workqueue by referencing a non-existing file

2022-04-21 Thread Sergey Raevskiy
I've noticed that in some cases a working copy can become inoperable after merge text conflict resolution with `svn_wc_conflict_choose_merged' option. The problem can occur in the following scenario: 1. There is a text conflict, that is resolved with `svn_wc_conflict_choose_merged' option

Re: Svnadmin dump with include can not dump the subdir into add when it's parent path was a branch

2020-03-23 Thread Sergey Raevskiy
Hello! I've attached a patch which adds a new option (--include-parents) to 'svnadmin dump'. This option works with existing --include option and includes parent nodes for nodes specified in --include option. This should fix the mentioned case. The option doesn't work with globbing for now, sin

[Patch] Rework of r1866425 ('Last-Modified' header)

2019-12-09 Thread Sergey Raevskiy
Hello! I've spent some time examining r1866425 [1] ('Last-Modified' header) and I would like to suggest a patch with some rework related to this code. I see two main problems in r1866425: usage of the pointer comparison (which is hackish and relies on the implementation of parse_uri()) and using

Re: svn commit: r1850651 - /subversion/trunk/subversion/mod_dav_svn/repos.c

2019-08-15 Thread Sergey Raevskiy
8:25 PM Stefan Sperling wrote: > > On Thu, Aug 15, 2019 at 08:14:43PM +0300, Sergey Raevskiy wrote: > > > /* if an authenticated username is present, attach it to the FS */ > > >if (r->user) > > > @@ -2503,6 +2529,14 @@ get_resource(request_rec *r, &g

Re: svn commit: r1850651 - /subversion/trunk/subversion/mod_dav_svn/repos.c

2019-08-15 Thread Sergey Raevskiy
> /* if an authenticated username is present, attach it to the FS */ >if (r->user) > @@ -2503,6 +2529,14 @@ get_resource(request_rec *r, >apr_pool_cleanup_register(r->pool, cleanup_baton, cleanup_fs_access, > apr_pool_cleanup_null); > > + /* We mu

Re: [PATCH] Add '--include' and '--exclude' options to 'svnadmin dump'

2019-02-21 Thread Sergey Raevskiy
Great! I have tried to make a patch to fix #4672, but it didn't work right away. Going to look again later. On Mon, Feb 18, 2019 at 1:39 PM Julian Foad wrote: > > Thank you, Sergey! Committed and proposed for backport. > > A similar (but not the same) problem exists with copies in "svnrdump dum

Re: [PATCH] Add '--include' and '--exclude' options to 'svnadmin dump'

2019-02-12 Thread Sergey Raevskiy
cmdline/svnadmin_tests.py (dump_include_copied_directory): New. (test_list): Add new test to table. Patch by: sergey.raevskiy{_AT_}visualsvn.com ]]] On Fri, Feb 8, 2019 at 6:27 PM Julian Foad wrote: > > Sergey Raevskiy wrote: > > > Ping! Sergey or anyone, are you able to investigate this? > &g

Re: [PATCH] Add '--include' and '--exclude' options to 'svnadmin dump'

2019-02-08 Thread Sergey Raevskiy
#x27;s > > contents. That sounds to me like a bug -- it is not the behaviour I > > would expect. > > > > I see that the regression tests only test with an empty source directory. > > subversion/tests/cmdline/svnadmin_tests.py : dump_exclude_copysource() > >

Re: [PATCH] Add '--include' and '--exclude' options to 'svnadmin dump'

2016-10-12 Thread Sergey Raevskiy
27; tries to add copy of '/A', but node '/A' is not included in destination dump. On Wed, Oct 12, 2016 at 2:10 PM, Bert Huijben wrote: > > >> -Original Message- >> From: Sergey Raevskiy [mailto:sergey.raevs...@visualsvn.com] >> Sent: woensdag 12 ok

[PATCH] Add '--include' and '--exclude' options to 'svnadmin dump'

2016-10-12 Thread Sergey Raevskiy
Hi! I've attached a patch that adds '--include/--exclude' options to 'svnadmin dump'. These options work similarly to 'svndumpfilter include/exclude' but provide proper handling of 'copy from' paths. Consider the following example with svndumpfilter: [[ $ svnadmin create /repo $ svn mkdir -m "" f

Re: JavaHL: Hard crash in libsvn_subr-1.dll

2015-09-10 Thread Sergey Raevskiy
After digging in some disassembly, I've guessed the [libsvn_subr-1.dll+0xc4c20] as svn_relpath_join() which is called with BASE == NULL. So, the crash might be caused by the same issue as in [1] which was already fixed in r1702198 [2]. [1] http://svn.haxx.se/dev/archive-2015-09/0070.shtml [2] h

Re: [PATCH] Don't remove empty directories when creating repositories (in some cases)

2015-04-01 Thread Sergey Raevskiy
After a little discussion with Daniel on IRC I've decided to use 'compatible-version' approach. Setting 'compatible-version' to 1.0.0 should force to fail creation of new FSFS filesystem, since it first appeared in Subversion 1.1. This should also be true for FSX (or any other hypothetical backen

Re: [PATCH] Don't remove empty directories when creating repositories (in some cases)

2015-04-01 Thread Sergey Raevskiy
Thanks for the reviews! > If you want to force fail because of the existing directory, I suggest > you create a directory and then do the equivalent of 'chmod -w' on it. Unfortunately, making the directory unwritable will cause svn_repos_create() to fail *before* attempting the FS creation and th

Re: [PATCH] Don't remove empty directories when creating repositories (in some cases)

2015-03-31 Thread Sergey Raevskiy
> Wouldn't it be easier, and a smaller patch, to add a check in > svn_repos_create that the FS type is valid /before/ creating the > repository structure? This would also avoid adding yet another public API. As I understand there is no public API for checking if FS-type is valid and corresponding

[PATCH] Don't remove empty directories when creating repositories (in some cases)

2015-03-30 Thread Sergey Raevskiy
Hi! I've noticed inconsistency in svn_repos_create() behavior. Despite the fact that creation of repositories over empty directories is allowed, in some cases this function will remove an empty directory that existed before repository creation. I've attached the patch with test and fix. [[[ Whe

Re: [Texts] Тексты по задаче K531

2015-02-16 Thread Sergey Raevskiy
Please ignore this e-mail (I accidentally sent it to the wrong mailing list).

[Texts] Тексты по задаче K531

2015-02-16 Thread Sergey Raevskiy
Коллеги, для задачи K531 на нужно утвердить следующие тексты: 1) Текст для ситуации, когда post-lock hook выдал ошибку на master (при выполнении svn lock через slave) Keyword: MSG_VDFS_POST_LOCK_HOOK_ERROR Сейчас: [[[ An error occurred with post-processing of lock operation. Repository: master P

Re: [PATCH] Fix pool usage in FSFS locking code

2015-02-12 Thread Sergey Raevskiy
> I think info->path is already in the correct pool, it's the result of > processing the the input path through svn_fspath__canonicalize using > result_pool. Yes, INFO->PATH is alocated in correct pool already. I've attached a new version of my patch (log message remains the same). Index: subvers

[PATCH] Fix pool usage in FSFS locking code

2015-02-12 Thread Sergey Raevskiy
Hi! I've noticed an improper pool usage in FSFS code. The svn_lock_t * object is created in RESULT_POOL, but its fiels are not gettting pstrdup'ed. The patch with fix is attached. Log message: [[[ * subversion/libsvn_fs_fs/lock.c (lock_body): Fix pool usage. Call apr_pstrdup() when initializi

Re: [PATCH/RFC] Simplify implementation of lock / unlock operations in FSFS

2015-02-11 Thread Sergey Raevskiy
>> Recently I've spent some time investigating how lock and unlock are >> implemented in FSFS and can suggest the following simplification. I >> attempted just to make this part clearer and a new code is intended to >> behave exactly the same. > > It's not exactly the same, index files are written

[PATCH/RFC] Simplify implementation of lock / unlock operations in FSFS

2015-02-11 Thread Sergey Raevskiy
Hi! Recently I've spent some time investigating how lock and unlock are implemented in FSFS and can suggest the following simplification. I attempted just to make this part clearer and a new code is intended to behave exactly the same. The patch is attached. Log message: [[[ Simplify implementa

Re: [Patch] Fix multiple reporting of the same lock in FSFS.

2015-02-10 Thread Sergey Raevskiy
>> I suspect the implementation is now more complicated than necessary. >> walk_locks and walk_locks_baton could be removed, walk_digest_files >> could be renamed to indicate that only a single digest file is accessed. >> The callers of walk_locks would call the renamed function directly. > > Yes.

Re: [Patch] Fix multiple reporting of the same lock in FSFS.

2015-02-09 Thread Sergey Raevskiy
> I suspect the implementation is now more complicated than necessary. > walk_locks and walk_locks_baton could be removed, walk_digest_files > could be renamed to indicate that only a single digest file is accessed. > The callers of walk_locks would call the renamed function directly. Yes. I'm goi

Re: [Patch] Fix multiple reporting of the same lock in FSFS.

2015-02-09 Thread Sergey Raevskiy
> This is issue 2507 > > http://subversion.tigris.org/issues/show_bug.cgi?id=2507 > > Commit does not remove locks, lock removal is a separate step after > commit. However that doesn't work well when a commit removes a locked > item, after such a commit the remaining lock is invalid and should not

[Patch] Fix multiple reporting of the same lock in FSFS.

2015-02-09 Thread Sergey Raevskiy
Hi! I've discovered interesting thing about the svn_fs_fs__get_locks() function. In some unusual, but not impossible scenarios this function could report the same lock multiple times: there should be the path with lock, and one of its children should be locked as well (see the test in attached pa

Re: [PATCH] Fix potential crash in libsvn_repos when executing pre-commit hook

2015-02-06 Thread Sergey Raevskiy
> I committed the test using /bin/sh, anything else is a lot more work and > possibly more likely to fail than to find a system without /bin/sh. I'm agree, other options seems to be less reliable and much more complicated. Finally, there is well-known practise of using /usr/bin/env (e.g. '#!/usr/

Re: [PATCH] Fix potential crash in libsvn_repos when executing pre-commit hook

2015-02-06 Thread Sergey Raevskiy
Thanks for the review! I really messed up the test. > How is that going to work? "exit 0" is not a valid hook script. It > might work with an additional "/bin/sh" but that is not portable. This will actually work on Windows, but yes, it isn't portable. > Ah! The fs layer does not run any hoo

[PATCH] Fix potential crash in libsvn_repos when executing pre-commit hook

2015-02-05 Thread Sergey Raevskiy
Hi! I've discovered another crash in lock-related code. Usage of deprecated API svn_fs_access_add_lock_token() function leads to crash when pre-commit hook is getting executed. Function svn_fs_access_add_lock_token() simply calls svn_fs_access_add_lock_token2() and passes some magic value ((cons

[PATCH] Fix possible crash in svn_fs_fs__lock() / svn_fs_fs__unlock()

2015-02-04 Thread Sergey Raevskiy
subversion/libsvn_fs_fs/lock.c (lock_body, svn_fs_fs__lock): Initialize the lb.infos field before calling to svn_fs_fs__with_write_lock(). (unlock_body, svn_fs_fs__unlock): Same. Patch by: Sergey Raevskiy ]]] Index:

Re: deleting locked file fails on 1.8.x

2014-05-16 Thread Sergey Raevskiy
> The problem can be fixed by merging subversion/trunk:r1553501,1553556,1559197 > with --accept=theirs-conflict (+ adding a missing svn_error_t *err; > declaration). This worked for me, all tests passed, including new one (Windows 8, httpd 2.2.27, svn 1.8.8, http x fsfs). BTW, should this be fil

Re: [PATCH/RFC] Lock refreshing problem in Subversion DAV layer

2014-04-04 Thread Sergey Raevskiy
> > + # Around trunk@1581815 refreshing of DAV lock fails with error > > + # '412 Precondition Failed' > You say it starts to fail at r859583 so how is 1581815 relevant? I've just tried to say that problem is still actual at r1581815.

[PATCH/RFC] Lock refreshing problem in Subversion DAV layer

2014-04-02 Thread Sergey Raevskiy
Do you have any suggestions about it? [1] https://tools.ietf.org/html/rfc2518 [2] http://svn.apache.org/r859583 [3] http://subversion.tigris.org/issues/show_bug.cgi?id=2275 Thanks and regards, Sergey Raevskiy Index: subversion/tests/cmdline/lock_tests.py ==

Re: [PATCH] Fix lock timeout values handling in libsvn_ra_serf

2014-03-21 Thread Sergey Raevskiy
this! On Thu, Mar 20, 2014 at 3:04 PM, Bert Huijben wrote: > > >> -Original Message- >> From: Sergey Raevskiy [mailto:sergey.raevs...@visualsvn.com] >> Sent: donderdag 20 maart 2014 09:47 >> To: Subversion Development >> Subject: [PATCH] Fix lock time

[PATCH] Fix lock timeout values handling in libsvn_ra_serf

2014-03-20 Thread Sergey Raevskiy
ge: [[[ Fix lock timeout value handling in libsvn_ra_serf: parse value in correct way. * subversion/libsvn_ra_serf/lock.c (locks_closed): Parse XML element value as TimeType Patch by: Sergey Raevskiy ]]] [1] https://tools.ietf.org/html/rfc4918 Th

Re: Crashes in 1.8.0 test suite on Solaris Sparc (wrong alignment in cache_lookup())

2013-06-20 Thread Sergey Raevskiy
> Rainer, can you check if the patch below works for you? > If so, we can merge both patches and put the new code into an #else block. > ... > + for (j = 0; j < 4; j++) > +val |= (path[i + j] << j); ... It seems that this sode should be: + for (j = 0; j < 4; j++) +val |=