julianf, stsp, neels


r930662 | dannas | 2010-04-04 05:55:25 -0500 (Sun, 04 Apr 2010)

Make 'svn patch' able to remove dirs beeing empty after patching, taking
into account both versioned and unversioned files and dirs.

* subversion/tests/cmdline/patch_tests.py
  (patch_remove_empty_dir): New.
  (test_list): Add new test.

* subversion/libsvn_client/patch.c
  (status_baton): New.
  (find_existing_children, is_dir_empty,
    add_target_to_hash_keyed_by_parent_dir, is_dir_empty,
    condense_deleted_targets): New functions
  (apply_patches): Call condense_deleted_targets(). Check if a
    target has a patch associated with it before calling
    svn_diff__close_patch() since we're creating targets to delete dirs
    and those have no associated patch.

Review by: julianf, stsp, neels