FreeBSD/contrib/subversion/subversion/libsvn_subr/sqlite.c
/* Unicode normalizing collation for WC paths */
Unicode normalizing collation for WC paths
Unicode normalizing collation for WC paths
static int
collate_ucs_nfd(void *baton,
                int len1, const void *key1,
                int len2, const void *key2)
{
  svn_sqlite__db_t *db = baton;
  int result;
  if (svn_utf__normcmp(key1, len1, key2, len2,
                       &db->sqlext_buf1, &db->sqlext_buf2, &result))
    {
      SVN_ERR_MALFUNCTION_NO_RETURN();
    }
  return result;
}
static int collate_ucs_nfd ( void * baton , int len1 , const void * key1 , int len2 , const void * key2 ) { svn_sqlite__db_t * db = baton ; int result ; if ( svn_utf__normcmp ( key1 , len1 , key2 , len2 , & db -> sqlext_buf1 , & db -> sqlext_buf2 , & result ) ) { SVN_ERR_MALFUNCTION_NO_RETURN ( ) ; } return result ; }
Unicode normalizing collation for WC paths
Unicode normalizing collation for WC paths
/* There is really nothing we can do here if an error occurs
         during Unicode normalizetion, and attempting to recover could
         result in the wc.db index being corrupted. Presumably this
         can only happen if the index already contains invalid UTF-8
         strings, which should never happen in any case ... */