Skip to content

Commit db9dfe7

Browse files
committed
[PGPRO-5771] Replace macro COMP_CRC32C with handler function.
Tags: ptrack
1 parent a0d5a20 commit db9dfe7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

engine.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
#include "access/xlog.h"
3232
#include "catalog/pg_tablespace.h"
3333
#include "miscadmin.h"
34-
#include "port/pg_crc32c.h"
34+
#include "common/checksum_helper.h"
3535
#include "storage/copydir.h"
3636
#if PG_VERSION_NUM >= 120000
3737
#include "storage/md.h"
@@ -73,7 +73,7 @@ ptrack_file_exists(const char *path)
7373
static void
7474
ptrack_write_chunk(int fd, pg_crc32c *crc, char *chunk, size_t size)
7575
{
76-
COMP_CRC32C(*crc, (char *) chunk, size);
76+
pg_comp_crc32c_handler(crc, (char *) chunk, size);
7777

7878
if (write(fd, chunk, size) != size)
7979
{
@@ -193,7 +193,7 @@ ptrackMapReadFromFile(const char *ptrack_path)
193193
pg_crc32c *file_crc;
194194

195195
INIT_CRC32C(crc);
196-
COMP_CRC32C(crc, (char *) ptrack_map, PtrackCrcOffset);
196+
pg_comp_crc32c_handler(&crc, (char *) ptrack_map, PtrackCrcOffset);
197197
FIN_CRC32C(crc);
198198

199199
file_crc = (pg_crc32c *) ((char *) ptrack_map + PtrackCrcOffset);

0 commit comments

Comments
 (0)