@@ -297,8 +297,6 @@ func (s *Server) GenerateConfiguration(ctx context.Context, in *machine.Generate
297
297
}
298
298
299
299
// Reboot implements the machine.MachineServer interface.
300
- //
301
- //nolint:dupl
302
300
func (s * Server ) Reboot (ctx context.Context , in * machine.RebootRequest ) (reply * machine.RebootResponse , err error ) {
303
301
actorID := uuid .New ().String ()
304
302
@@ -330,8 +328,6 @@ func (s *Server) Reboot(ctx context.Context, in *machine.RebootRequest) (reply *
330
328
}
331
329
332
330
// Rollback implements the machine.MachineServer interface.
333
- //
334
- //nolint:gocyclo
335
331
func (s * Server ) Rollback (ctx context.Context , in * machine.RollbackRequest ) (* machine.RollbackResponse , error ) {
336
332
log .Printf ("rollback via API received" )
337
333
@@ -407,8 +403,6 @@ func (s *Server) Bootstrap(ctx context.Context, in *machine.BootstrapRequest) (r
407
403
}
408
404
409
405
// Shutdown implements the machine.MachineServer interface.
410
- //
411
- //nolint:dupl
412
406
func (s * Server ) Shutdown (ctx context.Context , in * machine.ShutdownRequest ) (reply * machine.ShutdownResponse , err error ) {
413
407
actorID := uuid .New ().String ()
414
408
@@ -563,7 +557,7 @@ func (opt *ResetOptions) GetSystemDiskTargets() []runtime.PartitionTarget {
563
557
564
558
// Reset resets the node.
565
559
//
566
- //nolint:gocyclo,cyclop
560
+ //nolint:gocyclo
567
561
func (s * Server ) Reset (ctx context.Context , in * machine.ResetRequest ) (reply * machine.ResetResponse , err error ) {
568
562
actorID := uuid .New ().String ()
569
563
@@ -2229,7 +2223,7 @@ func (s *Server) PacketCapture(in *machine.PacketCaptureRequest, srv machine.Mac
2229
2223
if err = srv .SendMsg (& common.Data {Bytes : data }); err != nil {
2230
2224
cancel ()
2231
2225
2232
- pr .CloseWithError (err ) //nolint:errcheck
2226
+ pr .CloseWithError (err )
2233
2227
}
2234
2228
}
2235
2229
@@ -2244,7 +2238,7 @@ func capturePackets(pw *io.PipeWriter, handle *pcapgo.EthernetHandle, snapLen ui
2244
2238
pcapw := pcapgo .NewWriterNanos (pw )
2245
2239
2246
2240
if err := pcapw .WriteFileHeader (snapLen , linkType ); err != nil {
2247
- pw .CloseWithError (err ) //nolint:errcheck
2241
+ pw .CloseWithError (err )
2248
2242
2249
2243
return
2250
2244
}
@@ -2263,7 +2257,7 @@ func capturePackets(pw *io.PipeWriter, handle *pcapgo.EthernetHandle, snapLen ui
2263
2257
packet , err := pkgsrc .NextPacket ()
2264
2258
if err == nil {
2265
2259
if err = pcapw .WritePacket (packet .Metadata ().CaptureInfo , packet .Data ()); err != nil {
2266
- pw .CloseWithError (err ) //nolint:errcheck
2260
+ pw .CloseWithError (err )
2267
2261
2268
2262
return
2269
2263
}
@@ -2286,7 +2280,7 @@ func capturePackets(pw *io.PipeWriter, handle *pcapgo.EthernetHandle, snapLen ui
2286
2280
errors .Is (err , io .ErrNoProgress ) || errors .Is (err , io .ErrClosedPipe ) || errors .Is (err , io .ErrShortBuffer ) ||
2287
2281
errors .Is (err , syscall .EBADF ) ||
2288
2282
strings .Contains (err .Error (), "use of closed file" ) {
2289
- pw .CloseWithError (err ) //nolint:errcheck
2283
+ pw .CloseWithError (err )
2290
2284
2291
2285
return
2292
2286
}
0 commit comments