Skip to content
Commit 6a75ce16 authored by Eric W. Biederman's avatar Eric W. Biederman
Browse files

sysctl: Rewrite proc_sys_readdir in terms of first_entry and next_entry



Replace sysctl_head_next with first_entry and next_entry.  These new
iterators operate at the level of sysctl table entries and filter
out any sysctl tables that should not be shown.

Utilizing two specialized functions instead of a single function removes
conditionals for handling awkward special cases that only come up
at the beginning of iteration, making the iterators easier to read
and understand.

Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
parent 076c3eed
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment