Fix issue #4364: Correctly remove the stale entries from the lock table when
committing deletions.

* subversion/libsvn_client/commit.c
  (post_process_commit_item): always pass the flag to remove locks for deleted
    and replaced items.

* subversion/libsvn_wc/wc-queries.sql
  Add a new query which removes all lock rows recursively for a node.

* subversion/libsvn_wc/wc_db.h
  (svn_wc__db_base_remove): Add a new parameter remove_locks to recursively
    remove the lock rows.

* subversion/libsvn_wc/wc_db.c
  (svn_wc__db_base_remove): Forward the new remove_locks parameter to
    db_base_remove.
  (db_base_remove): Add and implement remove_locks.
  (commit_node): Also remove the locks recursively for subnodes of the
    current node.
  (bump_node_revision): Pass FALSE for remove_locks to get the old default
    behaviour.

* subversion/libsvn_wc/adm_ops.c
  (process_committed_leaf): In the shortcut for deleted nodes, pass TRUE to
    remove the locks recursively.

* subversion/libsvn_wc/crop.c
  (crop_children): Pass FALSE for remove_locks to get the old default
    behaviour.

* subversion/libsvn_wc/externals.c
  (svn_wc__external_remove): Pass FALSE for remove_locks to get the old
    default behaviour.

* subversion/libsvn_wc/update_editor.c
  (delete_entry, close_edit): Pass FALSE for remove_locks to get the old
    default behaviour.

* subversion/libsvn_wc/workqueue.c
  (run_base_remove): Pass FALSE for remove_locks to get the old default
    behaviour.

* subversion/tests/libsvn_wc/op-depth-test.c
  (base_dir_insert_remove): Pass FALSE for remove_locks to get the old default
    behaviour.

* subversion/tests/cmdline/lock_tests.py
  (def drop_locks_on_parent_deletion): Provide a regression test which catches
    reappearing locks.

Patch by: Markus Schaber <m.schaber{_AT_}codesys.com>
          (minor tweaks by me)


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1491756 13f79535-47bb-0310-9956-ffa450edef68