Skip to content

Commit

Permalink
fix(deps): patch libs to avoid segfaults in the main event loop
Browse files Browse the repository at this point in the history
Signed-off-by: Roberto Scolaro <[email protected]>
  • Loading branch information
therealbobo committed Mar 11, 2024
1 parent 0230044 commit 1e0fd10
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion cmake/modules/falcosecurity-libs-repo/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ ExternalProject_Add(
BUILD_COMMAND ""
INSTALL_COMMAND ""
TEST_COMMAND ""
PATCH_COMMAND sh -c "patch -p1 <${CMAKE_SOURCE_DIR}/chisel.patch"
PATCH_COMMAND sh -c "patch -p1 <${CMAKE_SOURCE_DIR}/chisel.patch && patch -p1 <${CMAKE_SOURCE_DIR}/eof.patch"
)
12 changes: 12 additions & 0 deletions cmake/modules/falcosecurity-libs-repo/eof.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
diff --git a/userspace/libsinsp/sinsp.cpp b/userspace/libsinsp/sinsp.cpp
index 29313a2b7..50ec4d6a1 100644
--- a/userspace/libsinsp/sinsp.cpp
+++ b/userspace/libsinsp/sinsp.cpp
@@ -1204,6 +1204,7 @@ int32_t sinsp::next(OUT sinsp_evt **puevt)
{
m_external_event_processor->process_event(NULL, libsinsp::EVENT_RETURN_EOF);
}
+ *puevt = evt;
}
else if(res == SCAP_UNEXPECTED_BLOCK)
{

0 comments on commit 1e0fd10

Please sign in to comment.