...

Text file src/github.com/cilium/ebpf/testdata/strings.c

Documentation: github.com/cilium/ebpf/testdata

     1#include "common.h"
     2
     3char __license[] __section("license") = "MIT";
     4
     5#define STR1 "This string is allocated in the string section\n"
     6#define STR2 "This one too\n"
     7
     8__section("socket") int filter() {
     9	trace_printk(STR1, sizeof(STR1));
    10	trace_printk(STR2, sizeof(STR2));
    11	return 0;
    12}

View as plain text