Lines Matching refs:context

24 PHP_HASH_API void PHP_CRC32Init(PHP_CRC32_CTX *context)  in PHP_CRC32Init()  argument
26 context->state = ~0; in PHP_CRC32Init()
29 PHP_HASH_API void PHP_CRC32Update(PHP_CRC32_CTX *context, const unsigned char *input, size_t len) in PHP_CRC32Update() argument
34 context->state = (context->state << 8) ^ crc32_table[(context->state >> 24) ^ (input[i] & 0xff)]; in PHP_CRC32Update()
38 PHP_HASH_API void PHP_CRC32BUpdate(PHP_CRC32_CTX *context, const unsigned char *input, size_t len) in PHP_CRC32BUpdate() argument
43 context->state = (context->state >> 8) ^ crc32b_table[(context->state ^ input[i]) & 0xff]; in PHP_CRC32BUpdate()
47 PHP_HASH_API void PHP_CRC32Final(unsigned char digest[4], PHP_CRC32_CTX *context) in PHP_CRC32Final() argument
49 context->state=~context->state; in PHP_CRC32Final()
50 digest[3] = (unsigned char) ((context->state >> 24) & 0xff); in PHP_CRC32Final()
51 digest[2] = (unsigned char) ((context->state >> 16) & 0xff); in PHP_CRC32Final()
52 digest[1] = (unsigned char) ((context->state >> 8) & 0xff); in PHP_CRC32Final()
53 digest[0] = (unsigned char) (context->state & 0xff); in PHP_CRC32Final()
54 context->state = 0; in PHP_CRC32Final()
57 PHP_HASH_API void PHP_CRC32BFinal(unsigned char digest[4], PHP_CRC32_CTX *context) in PHP_CRC32BFinal() argument
59 context->state=~context->state; in PHP_CRC32BFinal()
60 digest[0] = (unsigned char) ((context->state >> 24) & 0xff); in PHP_CRC32BFinal()
61 digest[1] = (unsigned char) ((context->state >> 16) & 0xff); in PHP_CRC32BFinal()
62 digest[2] = (unsigned char) ((context->state >> 8) & 0xff); in PHP_CRC32BFinal()
63 digest[3] = (unsigned char) (context->state & 0xff); in PHP_CRC32BFinal()
64 context->state = 0; in PHP_CRC32BFinal()