File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed
Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -769,14 +769,12 @@ let assert_can_be_recovered ~__context ~self ~session_to =
769769
770770let get_SRs_required_for_recovery ~__context ~self ~session_to =
771771 let required_SR_list = list_required_SRs ~__context ~self in
772- let required_SR_uuids = List. map( fun sr ->Db.SR. get_uuid ~__context ~self: sr) required_SR_list
773- in
774772 try
775- let sr_uuids_list=
776773 Server_helpers. exec_with_new_task ~session_id: session_to
777774 " Looking for the required SRs"
778775 (fun __context_to -> List. filter
779- ( fun sr_uuid ->
776+ ( fun sr_ref ->
777+ let sr_uuid = Db.SR. get_uuid ~__context ~self: sr_ref in
780778 try
781779 let sr = Db.SR. get_by_uuid ~__context:__context_to ~uuid: sr_uuid in
782780 let pbds = Db.SR. get_PBDs ~__context:__context_to ~self: sr in
@@ -787,9 +785,7 @@ let get_SRs_required_for_recovery ~__context ~self ~session_to =
787785 if attached_pbds = [] then true else false
788786 with Db_exn. Read_missing_uuid (_ , _ , sr_uuid ) -> true
789787 )
790- required_SR_uuids)
791- in
792- List. map(fun sr -> Db.SR. get_by_uuid ~__context ~uuid: sr)sr_uuids_list
788+ required_SR_list)
793789 with e -> raise e;;
794790
795791
You can’t perform that action at this time.
0 commit comments