Skip to content

Possible risk of temporary file collision #191

@JensRantil

Description

@JensRantil

I'm reading

filename := fmt.Sprintf("%s/s3_%d", os.TempDir(), rand.Uint32())
and
filename := fmt.Sprintf("%s/gs_%d", os.TempDir(), rand.Uint32())
and both has a slight risk of file name collisions. I propose migrating to use https://golang.org/pkg/io/ioutil/#TempFile which makes that scenario impossible.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions