@@ -2431,7 +2431,7 @@ fn map_pointer_operations(flow_key: FlowKey) {
24312431 // Map lookup returns pointer to value
24322432 var flow_data = flow_map[flow_key]
24332433
2434- if (flow_data != none ) {
2434+ if (flow_data != null ) {
24352435 // Direct modification through pointer
24362436 flow_data->packet_count += 1
24372437 flow_data->byte_count += packet_size
@@ -3016,7 +3016,7 @@ fn packet_filter(ctx: *xdp_md) -> action: xdp_action {
30163016
30173017// Userspace functions with named returns
30183018fn lookup_counter(ip: u32) -> counter_ptr: *u64 {
3019- if (counters[ip] == none ) {
3019+ if (counters[ip] == null ) {
30203020 counters[ip] = 0
30213021 }
30223022 counter_ptr = &counters[ip]
@@ -3737,7 +3737,7 @@ fn security_filter(ctx: LsmContext) -> i32 {
37373737 var flow_key = extract_flow_key_from_socket(ctx)
37383738
37393739 // Check global flow statistics for threat detection
3740- if (global_flows[flow_key] != none ) {
3740+ if (global_flows[flow_key] != null ) {
37413741 var flow_stats = global_flows[flow_key]
37423742 if (flow_stats.is_suspicious()) {
37433743 global_events.submit(EVENT_THREAT_DETECTED { flow_key })
@@ -4029,7 +4029,7 @@ var cache_map : hash<u32, DataCache>(1024)
40294029@helper
40304030fn map_lifetime_safety(key: u32) {
40314031 var cache_entry = cache_map[key]
4032- if (cache_entry != none ) {
4032+ if (cache_entry != null ) {
40334033 // Compiler tracks that cache_entry is valid here
40344034 cache_entry->access_count += 1
40354035 cache_entry->last_access = bpf_ktime_get_ns()
@@ -4085,7 +4085,7 @@ fn kernel_side_processing(ctx: *xdp_md) -> xdp_action {
40854085
40864086 // Shared memory through maps - safe across contexts
40874087 var shared_buffer = shared_map[0]
4088- if (shared_buffer != none ) {
4088+ if (shared_buffer != null ) {
40894089 shared_buffer->kernel_processed_count += 1
40904090 memory_copy(packet_data, shared_buffer->data, min(packet_len, 64))
40914091 }
@@ -4100,7 +4100,7 @@ fn userspace_processing() -> i32 {
41004100
41014101 // ✅ Access through shared maps
41024102 var shared_buffer = shared_map[0]
4103- if (shared_buffer != none ) {
4103+ if (shared_buffer != null ) {
41044104 shared_buffer->userspace_processed_count += 1
41054105 process_shared_data(shared_buffer->data)
41064106 }
0 commit comments