chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
core: clean up some confusing regarding SI decimal and IEC binary suffixes for sizes
[elogind.git]
/
src
/
systemctl
/
systemctl.c
diff --git
a/src/systemctl/systemctl.c
b/src/systemctl/systemctl.c
index 3375bac985566dc6b3d8ebb9f8e33a6712193c2f..c5ca8dc11d19e5bd7195fa9885e12bc697dc909a 100644
(file)
--- a/
src/systemctl/systemctl.c
+++ b/
src/systemctl/systemctl.c
@@
-4045,7
+4045,7
@@
static int append_assignment(sd_bus_message *m, const char *assignment) {
} else if (streq(field, "MemoryLimit")) {
off_t bytes;
} else if (streq(field, "MemoryLimit")) {
off_t bytes;
- r = parse_
bytes(eq
, &bytes);
+ r = parse_
size(eq, 1024
, &bytes);
if (r < 0) {
log_error("Failed to parse bytes specification %s", assignment);
return -EINVAL;
if (r < 0) {
log_error("Failed to parse bytes specification %s", assignment);
return -EINVAL;
@@
-4115,7
+4115,7
@@
static int append_assignment(sd_bus_message *m, const char *assignment) {
return -EINVAL;
}
return -EINVAL;
}
- r = parse_
bytes(bandwidth
, &bytes);
+ r = parse_
size(bandwidth, 1000
, &bytes);
if (r < 0) {
log_error("Failed to parse byte value %s.", bandwidth);
return -EINVAL;
if (r < 0) {
log_error("Failed to parse byte value %s.", bandwidth);
return -EINVAL;