@@ -1939,7 +1939,7 @@ func (s *service) PauseVM(ctx context.Context, req *proto.PauseVMRequest) (*empt
1939
1939
}
1940
1940
if ! strings .Contains (resp .Status , "204" ) {
1941
1941
s .logger .WithError (err ).Error ("Failed to pause VM" )
1942
- return nil , err
1942
+ return nil , errors . New ( "Failed to pause VM" )
1943
1943
}
1944
1944
1945
1945
return & empty.Empty {}, nil
@@ -1960,7 +1960,7 @@ func (s *service) ResumeVM(ctx context.Context, req *proto.ResumeVMRequest) (*em
1960
1960
}
1961
1961
if ! strings .Contains (resp .Status , "204" ) {
1962
1962
s .logger .WithError (err ).Error ("Failed to resume VM" )
1963
- return nil , err
1963
+ return nil , errors . New ( "Failed to resume VM" )
1964
1964
}
1965
1965
return & empty.Empty {}, nil
1966
1966
}
@@ -1996,7 +1996,7 @@ func (s *service) LoadSnapshot(ctx context.Context, req *proto.LoadSnapshotReque
1996
1996
if ! strings .Contains (resp .Status , "204" ) {
1997
1997
s .logger .WithError (err ).Error ("Failed to load VM from snapshot" )
1998
1998
s .logger .WithError (err ).Errorf ("Status of request: %s" , resp .Status )
1999
- return nil , err
1999
+ return nil , errors . New ( "Failed to load VM from snapshot" )
2000
2000
}
2001
2001
2002
2002
return & proto.LoadResponse {FirecrackerPID : strconv .Itoa (s .firecrackerPid )}, nil
@@ -2017,7 +2017,7 @@ func (s *service) CreateSnapshot(ctx context.Context, req *proto.CreateSnapshotR
2017
2017
}
2018
2018
if ! strings .Contains (resp .Status , "204" ) {
2019
2019
s .logger .WithError (err ).Error ("Failed to make snapshot of VM" )
2020
- return nil , err
2020
+ return nil , errors . New ( "Failed to make snapshot of VM" )
2021
2021
}
2022
2022
2023
2023
return & empty.Empty {}, nil
0 commit comments