mirror of
https://github.com/systemd/systemd.git
synced 2025-01-25 10:04:04 +03:00
string-util: add on_off
This commit is contained in:
parent
e8ac916ec3
commit
35dab95cdd
@ -74,6 +74,10 @@ static inline const sd_char *yes_no(bool b) {
|
||||
return b ? STR_C("yes") : STR_C("no");
|
||||
}
|
||||
|
||||
static inline const sd_char *on_off(bool b) {
|
||||
return b ? STR_C("on") : STR_C("off");
|
||||
}
|
||||
|
||||
static inline const sd_char* comparison_operator(int result) {
|
||||
return result < 0 ? STR_C("<") : result > 0 ? STR_C(">") : STR_C("==");
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user