Rediff patches

Drop 0008-dont-fail-on-0-sized-data-fed-to-json-parser.patch: <REASON>
Drop 0009-allow-multiple-calls-to-FeedData.patch: <REASON>
ubuntu/groovy
Jason Rhinelander 5 years ago
parent 0519e4f30f
commit ee11e59a26

@ -11,10 +11,10 @@ instead to run the test suite in the build.
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 79d60e1..054aa57 100644
index d5df651..252bd0c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -259,10 +259,6 @@ add_subdirectory(llarp)
@@ -268,10 +268,6 @@ add_subdirectory(llarp)
add_subdirectory(libabyss)
add_subdirectory(daemon)

@ -9,7 +9,7 @@ doesn't work with debian's temporary install location).
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/daemon/CMakeLists.txt b/daemon/CMakeLists.txt
index 685436f..a6bd0ff 100644
index c57e2ac..0c5b464 100644
--- a/daemon/CMakeLists.txt
+++ b/daemon/CMakeLists.txt
@@ -36,7 +36,7 @@ else()

@ -10,7 +10,7 @@ log.
1 file changed, 5 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 054aa57..4b2f525 100644
index 252bd0c..d6e2c1d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,10 +1,5 @@

@ -8,7 +8,7 @@ Rather than cramming it into CXXFLAGS in debian/rules.
1 file changed, 3 insertions(+)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4b2f525..731b479 100644
index d6e2c1d..c3857d5 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -39,6 +39,9 @@ endif()

@ -1,21 +0,0 @@
From: Jeff Becker <jeff@i2p.rocks>
Date: Sun, 15 Dec 2019 11:59:26 -0500
Subject: dont fail on 0 sized data fed to json parser
---
llarp/util/json.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/llarp/util/json.cpp b/llarp/util/json.cpp
index 9c9358c..1f0fd22 100644
--- a/llarp/util/json.cpp
+++ b/llarp/util/json.cpp
@@ -23,6 +23,8 @@ namespace llarp
bool
FeedData(const char* buf, size_t sz) override
{
+ if(sz == 0)
+ return true;
if(m_Offset + sz > m_Buf.size() - 1)
return false;
std::copy(buf, buf + sz, m_Buf.begin());

@ -1,21 +0,0 @@
From: Jeff Becker <jeff@i2p.rocks>
Date: Sun, 15 Dec 2019 12:01:29 -0500
Subject: allow multiple calls to FeedData
---
llarp/util/json.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llarp/util/json.cpp b/llarp/util/json.cpp
index 1f0fd22..ef569c1 100644
--- a/llarp/util/json.cpp
+++ b/llarp/util/json.cpp
@@ -27,7 +27,7 @@ namespace llarp
return true;
if(m_Offset + sz > m_Buf.size() - 1)
return false;
- std::copy(buf, buf + sz, m_Buf.begin());
+ std::copy_n(buf, sz, m_Buf.data() + m_Offset);
m_Offset += sz;
m_Buf[m_Offset] = 0;
return true;

@ -5,5 +5,3 @@
0005-Move-default-user-group-into-deb-patch.patch
0006-Add-no-resolvconf-hack-to-default-config.patch
0007-Pass-debian-version-as-GIT_VERSION.patch
0008-dont-fail-on-0-sized-data-fed-to-json-parser.patch
0009-allow-multiple-calls-to-FeedData.patch

Loading…
Cancel
Save