FreeBSD/contrib/subversion/subversion/libsvn_subr/checksum.c
/* Return a checksum object, allocated in POOL.  The checksum will be of
 * type KIND and contain the given DIGEST.
 */
Return a checksum object, allocated in POOL.  The checksum will be of
type KIND and contain the given DIGEST.
Return a checksum object allocated in POOL . The checksum will be of type KIND and contain the given DIGEST .
static svn_checksum_t *
checksum_create(svn_checksum_kind_t kind,
                const unsigned char *digest,
                apr_pool_t *pool)
{
  apr_size_t digest_size = DIGESTSIZE(kind);
  svn_checksum_t *checksum = checksum_create_without_digest(kind, digest_size,
                                                            pool);
  memcpy((unsigned char *)checksum->digest, digest, digest_size);
  return checksum;
}
static svn_checksum_t * checksum_create ( svn_checksum_kind_t kind , const unsigned char * digest , apr_pool_t * pool ) { apr_size_t digest_size = DIGESTSIZE ( kind ) ; svn_checksum_t * checksum = checksum_create_without_digest ( kind , digest_size , pool ) ; memcpy ( ( unsigned char * ) checksum -> digest , digest , digest_size ) ; return checksum ; }
Return a checksum object, allocated in POOL.
Return a checksum object allocated in POOL .