mirror of
https://github.com/clearml/dropbear
synced 2025-01-31 02:46:58 +00:00
bring back fsync_parent_dir
This commit is contained in:
parent
8f123fb618
commit
b2007beeb0
@ -152,6 +152,10 @@ int signkey_generate(enum signkey_type keytype, int bits, const char* filename,
|
||||
}
|
||||
}
|
||||
|
||||
/* ensure directory update is flushed to disk, otherwise we can end up
|
||||
with zero-byte hostkey files if the power goes off */
|
||||
fsync_parent_dir(filename);
|
||||
|
||||
out:
|
||||
if (buf) {
|
||||
buf_burn(buf);
|
||||
|
Loading…
Reference in New Issue
Block a user