Remove get_struct_char_array_ptr in favour of get_char_array_ptr_and_size, wrap it in get_or_crate_ptr_from_arg to use in bpf_helper_handler

This commit is contained in:
Pragyansh Chaturvedi
2025-11-07 18:54:59 +05:30
parent 3ccd3f767e
commit 2f4a7d2f90
3 changed files with 11 additions and 51 deletions

View File

@ -8,7 +8,6 @@ from .helper_utils import (
get_flags_val,
get_data_ptr_and_size,
get_buffer_ptr_and_size,
get_char_array_ptr_and_size,
get_ptr_from_arg,
get_int_value_from_arg,
)
@ -464,7 +463,7 @@ def bpf_probe_read_kernel_str_emitter(
)
# Get destination buffer (char array -> i8*)
dst_ptr, dst_size = get_char_array_ptr_and_size(
dst_ptr, dst_size = get_or_create_ptr_from_arg(
call.args[0], builder, local_sym_tab, struct_sym_tab
)