[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Bug in svn_wc__entries_write?

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2002-09-23 17:36:53 CEST

Hello

While implementing the access baton stuff I came across this in
libsvn_wc/entries.c:svn_wc__entries_write (I added the BUG comment in
r3206)

  svn_xml_make_close_tag (&bigstr, pool, SVN_WC__ENTRIES_TOPLEVEL);

  apr_err = apr_file_write_full (outfile, bigstr->data, bigstr->len, NULL);
  if (apr_err)
    err = svn_error_createf (apr_err, 0, NULL, pool,
                             "svn_wc__entries_write: %s",
                             svn_wc_adm_access_path (adm_access));
      
  /* Close & sync. ### BUG? Why do we sync if the write failed? */
  err2 = svn_wc__close_adm_file (outfile, svn_wc_adm_access_path (adm_access),
                                 SVN_WC__ADM_ENTRIES, 1, pool);

I do not understand why we would want to sync the entries file if the
write fails, doing so would seem to produce an incomplete, or corrupt,
entries file. Is this a bug, or am I missing something?

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Sep 23 17:38:02 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.