summaryrefslogtreecommitdiff
path: root/LICENSES/dual
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2020-06-08 13:44:16 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2022-10-23 18:06:56 -0400
commit4b0e21d64253f56fa5b177e08383934680957697 (patch)
tree5b5475397003b5db67a780c558c21b3601ed9a7e /LICENSES/dual
parent922ef161b21e605bf803f65dc928fabefb735702 (diff)
[elf][regset] simplify thread list handling in fill_note_info()
fill_note_info() iterates through the list of threads collected in mm->core_state->dumper, allocating a struct elf_thread_core_info instance for each and linking those into a list. We need the entry corresponding to current to be first in the resulting list, so the logics for list insertion is if it's for current or list is empty insert in the head else insert after the first element However, in mm->core_state->dumper the entry for current is guaranteed to be the first one. Which means that both parts of condition will be true on the first iteration and neither will be true on all subsequent ones. Taking the first iteration out of the loop simplifies things nicely... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'LICENSES/dual')
0 files changed, 0 insertions, 0 deletions