diff options
author | Lennart Poettering <lennart@poettering.net> | 2011-07-06 00:47:39 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2011-07-06 00:47:42 +0200 |
commit | a75560529663e5fd055884e32ab9c73f47f8aaa5 (patch) | |
tree | 38a52e5176648f51ed823616c4316ed0e2fa1fe6 /src/main.c | |
parent | 38a285d776cc0bf4440efe79fc7691032bcf3d67 (diff) |
manager: merge serialization and desrialization counter into one, and increase it when reexecuting
Instead of having individual counters n_serializing and n_deserializing
have a single one n_reloading, which should be sufficient.
Set n_reloading when we are about to go down for reexecution to avoid
cgroup trimming when we free the units for reexecution.
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c index 76a0943832..5a8ef529d2 100644 --- a/src/main.c +++ b/src/main.c @@ -898,6 +898,9 @@ static int prepare_reexecute(Manager *m, FILE **_f, FDSet **_fds) { assert(_f); assert(_fds); + /* Make sure nothing is really destructed when we shut down */ + m->n_reloading ++; + if ((r = manager_open_serialization(m, &f)) < 0) { log_error("Failed to create serialization file: %s", strerror(-r)); goto fail; |