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

[PATCH][merge-tracking]Clarity fix

From: Kamesh Jayachandran <kamesh_at_collab.net>
Date: 2006-11-15 09:33:33 CET

Hi All,

Find the attached patch and log.

With regards
Kamesh Jayachandran

[[[
Clarity fix.

* subversion/libsvn_fs_util/merge-info-sqlite-index.c
  (parse_mergeinfo_from_db):
   Changing from 'while' to 'do...while' as we know this block is exercised
   iff we have atleast one record.
   
Patch by: Kamesh Jayachandran <kamesh@collab.net>
Suggested by: Daniel L Rall <dlr@collab.net>
]]]

Index: subversion/libsvn_fs_util/merge-info-sqlite-index.c
===================================================================
--- subversion/libsvn_fs_util/merge-info-sqlite-index.c (revision 22305)
+++ subversion/libsvn_fs_util/merge-info-sqlite-index.c (working copy)
@@ -319,7 +319,7 @@
       *result = apr_hash_make(pool);
       pathranges = apr_array_make(pool, 1, sizeof(svn_merge_range_t *));
 
- while (sqlite_result == SQLITE_ROW)
+ do
         {
           svn_merge_range_t *temprange;
 
@@ -343,6 +343,8 @@
           sqlite_result = sqlite3_step(stmt);
           lastmergedfrom = mergedfrom;
         }
+ while (sqlite_result == SQLITE_ROW);
+
       apr_hash_set(*result, mergedfrom, APR_HASH_KEY_STRING, pathranges);
 
       if (sqlite_result != SQLITE_DONE)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Nov 15 09:33:57 2006

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.