diff options
| author | Luis Felipe Hernandez <[email protected]> | 2024-12-18 02:55:41 +0000 |
|---|---|---|
| committer | Madhavan Srinivasan <[email protected]> | 2024-12-18 08:11:23 +0000 |
| commit | e834166822a3c9fb403411c898367df8dabf973c (patch) | |
| tree | 6f051fb4669f07570ddafafd221ebbb6b403a404 /tools/testing/selftests/net/lib/py/utils.py | |
| parent | selftest/powerpc/ptrace: Cleanup duplicate macro definitions (diff) | |
| download | kernel-e834166822a3c9fb403411c898367df8dabf973c.tar.gz kernel-e834166822a3c9fb403411c898367df8dabf973c.zip | |
macintosh: declare ctl_table as const
Since commit 7abc9b53bd51 ("sysctl: allow registration of const struct
ctl_table"), the sysctl registration API allows struct ctl_table variables
to be placed into read-only memory.
mac_hid_files is registered as a sysctl table and should be treated as
read-only. By declaring the mac_hid_files structure as const, we ensure
that it cannot be accidentally modified. This change improves safety.
Suggested-by: Thomas Weißschuh <[email protected]>
Suggested-by: Ricardo B. Marliere <[email protected]>
Reviewed-by: Ricardo B. Marliere <[email protected]>
Signed-off-by: Luis Felipe Hernandez <[email protected]>
Signed-off-by: Madhavan Srinivasan <[email protected]>
Link: https://patch.msgid.link/[email protected]
Diffstat (limited to 'tools/testing/selftests/net/lib/py/utils.py')
0 files changed, 0 insertions, 0 deletions
