# SPDX-FileCopyrightText: 2025 Espressif Systems (Shanghai) CO LTD # SPDX-License-Identifier: Apache-2.0 import re import sys # Configurable prefix for memory functions MDNS_MEM_PREFIX = 'mdns_mem_' # Change this to modify the prefix def add_prefix_to_mem_funcs(content): # List of memory functions to prefix mem_funcs = [ 'malloc', 'calloc', 'free', 'strdup', 'strndup' ] # Create regex pattern matching the memory functions but not already prefixed ones pattern = fr'(?') sys.exit(1) process_file(sys.argv[1])