diff --git a/src/core/bpf_object.cpp b/src/core/bpf_object.cpp index b3d66a5..fd80c8f 100644 --- a/src/core/bpf_object.cpp +++ b/src/core/bpf_object.cpp @@ -1,9 +1,10 @@ -#include "bpf_object.h" -#include "bpf_exception.h" -#include "bpf_map.h" -#include "bpf_program.h" +#include "core/bpf_object.h" +#include "core/bpf_exception.h" +#include "core/bpf_map.h" +#include "core/bpf_program.h" #include "utils/struct_parser.h" #include +#include #include BpfObject::BpfObject(std::string object_path, py::dict structs) @@ -263,9 +264,9 @@ py::dict BpfObject::get_cached_maps() const { } std::shared_ptr BpfObject::get_struct_parser() const { - if (!struct_parser_ && !struct_defs_.empty()) { - // Create parser on first access - struct_parser_ = std::make_shared(struct_defs_); - } - return struct_parser_; + if (!struct_parser_ && !struct_defs_.empty()) { + // Create parser on first access + struct_parser_ = std::make_shared(struct_defs_); + } + return struct_parser_; } diff --git a/src/core/bpf_object.h b/src/core/bpf_object.h index b5ec4e9..bbc0576 100644 --- a/src/core/bpf_object.h +++ b/src/core/bpf_object.h @@ -6,7 +6,6 @@ #include #include #include -#include namespace py = pybind11;