[lxc-devel] [lxc/master] 2020 12 07/bugfixes

brauner on Github lxc-bot at linuxcontainers.org
Mon Dec 7 10:29:44 UTC 2020


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 301 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20201207/6c528658/attachment.bin>
-------------- next part --------------
From 052535c8657e2671ce5de5b4fae4c6f293a8d76c Mon Sep 17 00:00:00 2001
From: Christian Brauner <christian.brauner at ubuntu.com>
Date: Mon, 7 Dec 2020 11:25:58 +0100
Subject: [PATCH 1/2] macro: move MAX_GRBUF_SIZE

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>
---
 src/lxc/macro.h | 4 ++++
 src/lxc/utils.h | 4 ----
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/lxc/macro.h b/src/lxc/macro.h
index d6b9954e8d..c8e810a3dc 100644
--- a/src/lxc/macro.h
+++ b/src/lxc/macro.h
@@ -25,6 +25,10 @@
 #define PATH_MAX 4096
 #endif
 
+#ifndef MAX_GRBUF_SIZE
+#define MAX_GRBUF_SIZE 65536
+#endif
+
 #define INT64_FMT "%" PRId64
 
 /* Define __S_ISTYPE if missing from the C library. */
diff --git a/src/lxc/utils.h b/src/lxc/utils.h
index ddd1cbe620..4825599c4e 100644
--- a/src/lxc/utils.h
+++ b/src/lxc/utils.h
@@ -6,10 +6,6 @@
 /* Properly support loop devices on 32bit systems. */
 #define _FILE_OFFSET_BITS 64
 
-#ifndef MAX_GRBUF_SIZE
-#define MAX_GRBUF_SIZE 65536
-#endif
-
 #include <errno.h>
 #include <linux/loop.h>
 #include <linux/types.h>

From 703c2767c94e4850d39c18dbcc9d8601e9ccabb8 Mon Sep 17 00:00:00 2001
From: Christian Brauner <christian.brauner at ubuntu.com>
Date: Mon, 7 Dec 2020 11:28:42 +0100
Subject: [PATCH 2/2] macro: bump MAX_GRBUF_SIZE to 2 mb

Closes #3592.
Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>
---
 src/lxc/macro.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lxc/macro.h b/src/lxc/macro.h
index c8e810a3dc..2d5d683316 100644
--- a/src/lxc/macro.h
+++ b/src/lxc/macro.h
@@ -26,7 +26,7 @@
 #endif
 
 #ifndef MAX_GRBUF_SIZE
-#define MAX_GRBUF_SIZE 65536
+#define MAX_GRBUF_SIZE (1 << 31)
 #endif
 
 #define INT64_FMT "%" PRId64


More information about the lxc-devel mailing list