Skip to content

Commit f0a2dc0

Browse files
author
Emmanuel Merali
committed
Renamed crc32 to rcrc32
The function crc32 was not being called so I renamed it to make sure that it's being called
1 parent b408f7a commit f0a2dc0

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

redis_array.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ PHPAPI int redis_array_get(zval *id, RedisArray **ra TSRMLS_DC)
123123
return Z_LVAL_PP(socket);
124124
}
125125

126-
uint32_t crc32(const char *s, size_t sz) {
126+
uint32_t rcrc32(const char *s, size_t sz) {
127127

128128
static const uint32_t table[256] = {
129129
0x00000000,0x77073096,0xEE0E612C,0x990951BA,0x076DC419,0x706AF48F,0xE963A535,

redis_array.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ typedef struct RedisArray_ {
4141
struct RedisArray_ *prev;
4242
} RedisArray;
4343

44-
uint32_t crc32(const char *s, size_t sz);
44+
uint32_t rcrc32(const char *s, size_t sz);
4545

4646

4747
#endif

redis_array_impl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ ra_find_node(RedisArray *ra, const char *key, int key_len, int *out_pos TSRMLS_D
335335
return NULL;
336336

337337
/* hash */
338-
hash = crc32(out, out_len);
338+
hash = rcrc32(out, out_len);
339339
efree(out);
340340

341341
/* get position on ring */

0 commit comments

Comments
 (0)