• Jeromy's avatar
    bitswap: fix a minor data race · 3fbf157a
    Jeromy authored
    race detector picked up a minor race condition, Since loop iteration
    reuses the same local variable, its not safe to take its address and use
    it concurrently. The fix is to rebind the variable into a controlled
    scope (creating a new variable) and taking the address of that to pass
    outwards.
    
    License: MIT
    Signed-off-by: default avatarJeromy <why@ipfs.io>
    3fbf157a
workers.go 5.2 KB