]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/shared/cpu-set-util.c
cpu-set-util: Support ranges in parse_cpu_set_and_warn
authorFilipe Brandenburger <filbranden@google.com>
Fri, 25 Sep 2015 12:23:23 +0000 (05:23 -0700)
committerFilipe Brandenburger <filbranden@google.com>
Wed, 28 Oct 2015 00:56:26 +0000 (17:56 -0700)
commita26662ce9b25c400ead61854ed7be636f186fdb0
treef1441b826920f40ad03b738634208705741f28d6
parent28cb17ef0281efc3a46e5d0e702b0b0ddeaafaa4
cpu-set-util: Support ranges in parse_cpu_set_and_warn

Tested CPUAffinity ranges on both a service unit and in system.conf and
confirmed they work as expected (by inspecting /proc/PID/status, for the
main pid of the service and for pid 1).  Also mixed ranges with both
spaces, commas, trailing commas and spaces.

Added new tests to increase coverage of ranges and prevent regressions.
src/basic/cpu-set-util.c
src/test/test-util.c