chiark / gitweb /
tree-wide: use startswith return value to avoid hardcoded offset
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 22 Oct 2016 20:11:41 +0000 (16:11 -0400)
committerSven Eden <yamakuzure@gmx.net>
Mon, 17 Jul 2017 15:58:34 +0000 (17:58 +0200)
commit910c586574a52c6b4cbc6638193797008da076c7
tree43e6d4842f185439c9e22eeb45e56aea851f40aa
parent3b148b365934f5baf2c9162e2454ca416b666531
tree-wide: use startswith return value to avoid hardcoded offset

I think it's an antipattern to have to count the number of bytes in
the prefix by hand. We should do this automatically to avoid wasting
programmer time, and possible errors. I didn't any offsets that were
wrong, so this change is mostly to make future development easier.
src/core/cgroup.c