FreeBSD/contrib/subversion/subversion/libsvn_fs_fs/verify.c
/* Compare the ACTUAL checksum with the one expected by ENTRY.
 * Return an error in case of mismatch.  Use the name of FILE
 * in error message.  Allocate data in POOL.
 */
Compare the ACTUAL checksum with the one expected by ENTRY.
Return an error in case of mismatch.  Use the name of FILE
in error message.  Allocate data in POOL.
Compare the ACTUAL checksum with the one expected by ENTRY . Return an error in case of mismatch . Use the name of FILE in error message . Allocate data in POOL .
static svn_error_t *
expected_checksum(apr_file_t *file,
                  svn_fs_fs__p2l_entry_t *entry,
                  apr_uint32_t actual,
                  apr_pool_t *pool)
{
  if (actual != entry->fnv1_checksum)
    {
      const char *file_name;
      SVN_ERR(svn_io_file_name_get(&file_name, file, pool));
      return svn_error_createf(SVN_ERR_FS_CORRUPT, NULL,
                               _("Checksum mismatch in item at offset %s of "
                                 "length %s bytes in file %s"),
                               apr_off_t_toa(pool, entry->offset),
                               apr_off_t_toa(pool, entry->size), file_name);
    }
  return SVN_NO_ERROR;
}
static svn_error_t * expected_checksum ( apr_file_t * file , svn_fs_fs__p2l_entry_t * entry , apr_uint32_t actual , apr_pool_t * pool ) { if ( actual != entry -> fnv1_checksum ) { const char * file_name ; SVN_ERR ( svn_io_file_name_get ( & file_name , file , pool ) ) ; return svn_error_createf ( SVN_ERR_FS_CORRUPT , NULL , _ ( " " " " ) , apr_off_t_toa ( pool , entry -> offset ) , apr_off_t_toa ( pool , entry -> size ) , file_name ) ; } return SVN_NO_ERROR ; }
Compare the ACTUAL checksum with the one expected by ENTRY.
Compare the ACTUAL checksum with the one expected by ENTRY .