Skip to content

Commit 867f142

Browse files
committed
Fix includes for BpfObject
1 parent 8cc8f42 commit 867f142

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

src/core/bpf_object.cpp

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
#include "bpf_object.h"
2-
#include "bpf_exception.h"
3-
#include "bpf_map.h"
4-
#include "bpf_program.h"
1+
#include "core/bpf_object.h"
2+
#include "core/bpf_exception.h"
3+
#include "core/bpf_map.h"
4+
#include "core/bpf_program.h"
55
#include "utils/struct_parser.h"
66
#include <cerrno>
7+
#include <cstring>
78
#include <utility>
89

910
BpfObject::BpfObject(std::string object_path, py::dict structs)
@@ -263,9 +264,9 @@ py::dict BpfObject::get_cached_maps() const {
263264
}
264265

265266
std::shared_ptr<StructParser> BpfObject::get_struct_parser() const {
266-
if (!struct_parser_ && !struct_defs_.empty()) {
267-
// Create parser on first access
268-
struct_parser_ = std::make_shared<StructParser>(struct_defs_);
269-
}
270-
return struct_parser_;
267+
if (!struct_parser_ && !struct_defs_.empty()) {
268+
// Create parser on first access
269+
struct_parser_ = std::make_shared<StructParser>(struct_defs_);
270+
}
271+
return struct_parser_;
271272
}

src/core/bpf_object.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
#include <pybind11/pybind11.h>
77
#include <string>
88
#include <unordered_map>
9-
#include <vector>
109

1110
namespace py = pybind11;
1211

0 commit comments

Comments
 (0)