projects
/
project
/
uci.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a6a7453
)
file: remove unnecessary sync() call
author
Felix Fietkau
<nbd@openwrt.org>
Thu, 27 Aug 2015 12:40:57 +0000
(14:40 +0200)
committer
Felix Fietkau
<nbd@openwrt.org>
Thu, 27 Aug 2015 12:40:58 +0000
(14:40 +0200)
It can be too expensive during filesystem initialization, and it is not
required for atomic handling of config changes.
If the write gets interrupted, the config file will always contain
either the new state or the old state
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
file.c
patch
|
blob
|
history
diff --git
a/file.c
b/file.c
index cf0dfafc1cccb1e379bcb2653e13f4875b149692..341a7065cddd4e352aae360d596e651d694359c6 100644
(file)
--- a/
file.c
+++ b/
file.c
@@
-800,7
+800,6
@@
done:
UCI_THROW(ctx, UCI_ERR_IO);
}
free(filename);
- sync();
if (ctx->err)
UCI_THROW(ctx, ctx->err);
}