Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 28 Feb 2022 12:54:12 GMT
From:      Po-Chuan Hsieh <sunpoet@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: f6fe2ca40866 - main - sysutils/zbackup: Fix build with protobuf 3.18.0+
Message-ID:  <202202281254.21SCsCCd067808@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=f6fe2ca4086687efb4caa53523b977e25b3082a8

commit f6fe2ca4086687efb4caa53523b977e25b3082a8
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-02-28 09:43:30 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-02-28 12:46:46 +0000

    sysutils/zbackup: Fix build with protobuf 3.18.0+
    
    Deprecated 2-parameter SetTotalBytesLimit() has be removed since protobuf 3.18.0.
    
    Reference:      https://github.com/protocolbuffers/protobuf/commit/cda795437d00a15f375d3d5e2659adac715459c6
---
 sysutils/zbackup/files/patch-protobuf | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/sysutils/zbackup/files/patch-protobuf b/sysutils/zbackup/files/patch-protobuf
new file mode 100644
index 000000000000..a16775318d59
--- /dev/null
+++ b/sysutils/zbackup/files/patch-protobuf
@@ -0,0 +1,15 @@
+Deprecated 2-parameter SetTotalBytesLimit() has be removed since protobuf 3.18.0.
+
+Reference:	https://github.com/protocolbuffers/protobuf/commit/cda795437d00a15f375d3d5e2659adac715459c6
+
+--- backup_restorer.cc.orig	2015-09-16 07:28:04 UTC
++++ backup_restorer.cc
+@@ -27,7 +27,7 @@ void restore( ChunkStorage::Reader & chunkStorageReade
+   // TODO: this disables size checks for each separate message. Figure a better
+   // way to do this while keeping them enabled. It seems we need to create an
+   // instance of CodedInputStream for each message, but it might be expensive
+-  cis.SetTotalBytesLimit( backupData.size(), -1 );
++  cis.SetTotalBytesLimit( backupData.size() );
+ 
+   // Used when emitting chunks
+   string chunk;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202202281254.21SCsCCd067808>