Skip to content

Commit

Permalink
wip: standardize strarr buffer submit
Browse files Browse the repository at this point in the history
  • Loading branch information
NDStrahilevitz committed Oct 16, 2024
1 parent ebe9be2 commit 22d5ea7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pkg/ebpf/c/common/buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -260,8 +260,9 @@ statfunc int save_str_arr_to_buf(args_buffer_t *buf, const char __user *const __
statfunc int save_args_str_arr_to_buf(
args_buffer_t *buf, const char *start, const char *end, int elem_num, u8 index)
{
// Data saved to submit buf: [index][len][arg_len][arg #][null delimited string array]
// Note: This helper saves null (0x00) delimited string array into buf
// Data saved to submit buf: [index][len][arg_len][arg #][array of null delimited string]
// Note: This helper saves null (0x00) delimited string array into buf in the format:
// [[str1][\n][str2][\n][...][strn][\n])]

if (start >= end)
return 0;
Expand Down

0 comments on commit 22d5ea7

Please sign in to comment.