Skip to content

Commit ee32367

Browse files
jjd27robhoes
authored andcommitted
Domain.make: prefer Xst.writev over multiple Xst.write
Slightly improves code readability and reduces duplication. Signed-off-by: Jonathan Davies <[email protected]>
1 parent 473f4d4 commit ee32367

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

xc/domain.ml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -226,9 +226,11 @@ let make ~xc ~xs vm_info uuid =
226226
t.Xst.rm vss_path;
227227
t.Xst.mkdirperms vss_path rwperm;
228228

229-
t.Xst.write (dom_path ^ "/vm") vm_path;
230-
t.Xst.write (dom_path ^ "/vss") vss_path;
231-
t.Xst.write (dom_path ^ "/name") name;
229+
t.Xst.writev dom_path [
230+
"vm", vm_path;
231+
"vss", vss_path;
232+
"name", name;
233+
];
232234

233235
(* create cpu and memory directory with read only perms *)
234236
List.iter (fun dir ->

0 commit comments

Comments
 (0)