Skip to content

Commit 0071fc7

Browse files
committed
Fix header inclusion order in xloginsert.c with lz4.h
Per project policy, all system and library headers need to be declared in the backend code after "postgres.h" and before the internal headers, but 4035cd5 broke this policy when adding support for LZ4 in wal_compression. Noticed while reviewing the patch to add support for zstd in this area. This only impacts HEAD, so there is no need for a back-patch.
1 parent 352d297 commit 0071fc7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/backend/access/transam/xloginsert.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@
1919

2020
#include "postgres.h"
2121

22+
#ifdef USE_LZ4
23+
#include <lz4.h>
24+
#endif
25+
2226
#include "access/xact.h"
2327
#include "access/xlog.h"
2428
#include "access/xlog_internal.h"
@@ -38,7 +42,6 @@
3842
* backup block image.
3943
*/
4044
#ifdef USE_LZ4
41-
#include <lz4.h>
4245
#define LZ4_MAX_BLCKSZ LZ4_COMPRESSBOUND(BLCKSZ)
4346
#else
4447
#define LZ4_MAX_BLCKSZ 0

0 commit comments

Comments
 (0)