Checkout
Daniel Shahaf
committed
on 14 Jul 13
Short-circuit the UTF-8 conversion when the source encoding is UTF-8.

Do this by recognizing "UTF-8" as a magic number; that magic number… Show more
Short-circuit the UTF-8 conversion when the source encoding is UTF-8.  

Do this by recognizing "UTF-8" as a magic number; that magic number (well,

magic string) is already used once in svnsync's normalize_string().  The

reason for the short-circuit is that the conversion would be a no-op; see

<http://mid.gmane.org/20130714165516.GA71250@minotaur.apache.org>.

This fixes svnsync_authz_tests.py 5 when apr_xlate_open() returns something

other than APR_SUCCESS in utf.c:xlate_alloc_handle().

* subversion/libsvn_subr/subst.c

 (svn_subst_translate_string2): As above. Show less