Skip to content

fix: linter issue#2948

Merged
crosbymichael merged 1 commit intocontainerd:masterfrom
fuweid:fix_linter_issue
Jan 23, 2019
Merged

fix: linter issue#2948
crosbymichael merged 1 commit intocontainerd:masterfrom
fuweid:fix_linter_issue

Conversation

@fuweid
Copy link
Copy Markdown
Member

@fuweid fuweid commented Jan 23, 2019

megacheck, gosimple and unused has been deprecated and subsumed by
staticcheck. And staticcheck also has been upgraded. we need to update
code for the linter issue.

close: #2945

Signed-off-by: Wei Fu [email protected]

megacheck, gosimple and unused has been deprecated and subsumed by
staticcheck. And staticcheck also has been upgraded. we need to update
code for the linter issue.

close: containerd#2945

Signed-off-by: Wei Fu <[email protected]>
for s := range signals {
switch s {
case os.Interrupt:
break
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the original one doesn't break out of an outer loop so that I remove the break statement here

@codecov-io
Copy link
Copy Markdown

Codecov Report

Merging #2948 into master will increase coverage by <.01%.
The diff coverage is 56.25%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2948      +/-   ##
==========================================
+ Coverage   44.02%   44.02%   +<.01%     
==========================================
  Files         102      102              
  Lines       10870    10862       -8     
==========================================
- Hits         4785     4782       -3     
+ Misses       5351     5347       -4     
+ Partials      734      733       -1
Flag Coverage Δ
#linux 47.64% <80%> (-0.01%) ⬇️
#windows 41.24% <60%> (-0.01%) ⬇️
Impacted Files Coverage Δ
filters/scanner.go 68.36% <ø> (-0.18%) ⬇️
runtime/v2/shim/util_windows.go 0% <0%> (ø) ⬆️
runtime/v2/shim/shim_unix.go 0% <0%> (ø) ⬆️
runtime/v2/shim/shim_windows.go 41.1% <0%> (+0.25%) ⬆️
metadata/content.go 43.98% <100%> (ø) ⬆️
remotes/docker/auth.go 67.79% <100%> (ø) ⬆️
metadata/snapshot.go 45.8% <100%> (ø) ⬆️
content/local/locks.go 100% <100%> (ø) ⬆️
archive/tar_windows.go 8.87% <50%> (+0.08%) ⬆️
metadata/db.go 65.9% <75%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 35582cb...132ee9b. Read the comment docs.

1 similar comment
@codecov-io
Copy link
Copy Markdown

Codecov Report

Merging #2948 into master will increase coverage by <.01%.
The diff coverage is 56.25%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2948      +/-   ##
==========================================
+ Coverage   44.02%   44.02%   +<.01%     
==========================================
  Files         102      102              
  Lines       10870    10862       -8     
==========================================
- Hits         4785     4782       -3     
+ Misses       5351     5347       -4     
+ Partials      734      733       -1
Flag Coverage Δ
#linux 47.64% <80%> (-0.01%) ⬇️
#windows 41.24% <60%> (-0.01%) ⬇️
Impacted Files Coverage Δ
filters/scanner.go 68.36% <ø> (-0.18%) ⬇️
runtime/v2/shim/util_windows.go 0% <0%> (ø) ⬆️
runtime/v2/shim/shim_unix.go 0% <0%> (ø) ⬆️
runtime/v2/shim/shim_windows.go 41.1% <0%> (+0.25%) ⬆️
metadata/content.go 43.98% <100%> (ø) ⬆️
remotes/docker/auth.go 67.79% <100%> (ø) ⬆️
metadata/snapshot.go 45.8% <100%> (ø) ⬆️
content/local/locks.go 100% <100%> (ø) ⬆️
archive/tar_windows.go 8.87% <50%> (+0.08%) ⬆️
metadata/db.go 65.9% <75%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 35582cb...132ee9b. Read the comment docs.

Copy link
Copy Markdown
Member

@estesp estesp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - all these changes look reasonable to me

@crosbymichael
Copy link
Copy Markdown
Member

LGTM

@crosbymichael crosbymichael merged commit aee74ad into containerd:master Jan 23, 2019
@fuweid fuweid deleted the fix_linter_issue branch January 24, 2019 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Lint is broken

4 participants