mirror of
https://git.proxmox.com/git/proxmox
synced 2025-08-12 05:30:19 +00:00
tools: replace_file, make options not an option...
CreateOptions::new() creates an all-None option set anyway Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
2387f9ef2b
commit
4bce3d76a2
@ -74,9 +74,8 @@ pub fn file_read_firstline<P: AsRef<Path>>(path: P) -> Result<String, Error> {
|
||||
pub fn replace_file<P: AsRef<Path>>(
|
||||
path: P,
|
||||
data: &[u8],
|
||||
options: Option<CreateOptions>,
|
||||
options: CreateOptions,
|
||||
) -> Result<(), Error> {
|
||||
let options = options.unwrap_or_default();
|
||||
file_set_contents_full(
|
||||
path.as_ref(),
|
||||
data,
|
||||
|
Loading…
Reference in New Issue
Block a user