Uploaded image for project: 'Subversion'
  1. Subversion
  2. SVN-4192

wc locks not removes when automatic cleanup clears workqueue

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • trunk
    • 1.10-consider
    • libsvn_wc
    • None

    Description

      Pool cleanup attempts to remove run any outstanding workqueue items and remove
      working copy locks.  Lock removal when there are no workqueue items appears to
      work.  Workqueue running also appears to work.  However lock removal after
      running a workqueue item doesn't work.
      
      Patch update_editor.c:close_file to return an error.  Then run and update that
      modifies a file.  The working copy is left unlocked showing that lock removal
      without workqueue items works.
      
      Patch workqueue.c:run_file_install to return a one-time error:
      
      Index: ../src/subversion/libsvn_wc/workqueue.c
      ===================================================================
      --- ../src/subversion/libsvn_wc/workqueue.c     (revision 1349304)
      +++ ../src/subversion/libsvn_wc/workqueue.c     (working copy)
      @@ -645,6 +645,15 @@
         apr_hash_t *props;
         apr_time_t changed_date;
       
      +  {
      +    static int f = 1;
      +    if (f)
      +      {
      +        f = 0;
      +        return svn_error_createf(SVN_ERR_WC_PATH_NOT_FOUND, NULL, "foo");
      +      }
      +  }
      +
         local_relpath = apr_pstrmemdup(scratch_pool, arg1->data, arg1->len);
         SVN_ERR(svn_wc__db_from_relpath(&local_abspath, db, wri_abspath,
                                         local_relpath, scratch_pool, scratch_pool));
      
      Run the update that modifies a file.  The update fails and automatic cleanup
      runs the workqueue and the file gets the new content. The workqueue is empty but
      the working copy remains locked.
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            philipm Philip Martin
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: