Skip to content

chrootarchive: fix "conversion from int to string yields a string of one rune"#41153

Merged
tiborvass merged 1 commit intomoby:masterfrom
thaJeztah:fix_linting
Jun 25, 2020
Merged

chrootarchive: fix "conversion from int to string yields a string of one rune"#41153
tiborvass merged 1 commit intomoby:masterfrom
thaJeztah:fix_linting

Conversation

@thaJeztah
Copy link
Member

update test to fix go 1.15 linting failure:

pkg/chrootarchive/archive_test.go:103:32: conversion from int to string yields a string of one rune

relates to golang/go 32479

…one rune"

update test to fix go 1.15 linting failure:

    pkg/chrootarchive/archive_test.go:103:32: conversion from int to string yields a string of one rune

relates to golang/go 32479

Signed-off-by: Sebastiaan van Stijn <[email protected]>
@thaJeztah
Copy link
Member Author

@SamWhited @AkihiroSuda @cpuguy83 PTAL

excludes := make([]string, 65534)
for i := 0; i < 65534; i++ {
var i rune
for i = 0; i < 65534; i++ {
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: i is already 0. Alternatively, for i := rune(0); … might be a bit cleaner. But it doesn't really matter, LGTM either way.

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah, yes, could've done that 👍
Think I'll keep it as-if, as CI is a bit flaky (don't want to be running it multiple times to get green again 😞)

Copy link
Member

@cpuguy83 cpuguy83 left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants