Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: containerd/go-cni
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.1.11
Choose a base ref
...
head repository: containerd/go-cni
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v1.1.12
Choose a head ref
  • 2 commits
  • 11 files changed
  • 2 contributors

Commits on Dec 24, 2024

  1. fix: recursive RLock() mutex acquision

    There were at least two code paths which might acquire `.RLock()`
    recursively:
    
    1. `Setup*()` -> `createResult()`
    2. `Setup*()` -> `Networks()`.
    
    On its own, it's not a problem, but if `.Load()` is called concurrently,
    it might do `.Lock()` in between recursive `.RLock()`s, which would lead
    to a deadlock.
    
    See #125
    
    Fix by introducing a contract on the way mutex is acquired.
    
    Add a test facility to verify for such mistakes via build tags:
    
    * `go test -race` or `go test -tags deadlocks` activates deadlock
      detection
    
    Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
    smira committed Dec 24, 2024
    Configuration menu
    Copy the full SHA
    75a2440 View commit details
    Browse the repository at this point in the history

Commits on Jan 9, 2025

  1. Merge pull request #126 from smira/fix/deadlocks

    fix: recursive RLock() mutex acquision
    mikebrow authored Jan 9, 2025
    Configuration menu
    Copy the full SHA
    f4736bb View commit details
    Browse the repository at this point in the history
Loading