[19.03 backport] plugin: fix a double RLock bug
| ... | ... |
@@ -188,9 +188,7 @@ func (ps *Store) GetAllByCap(capability string) ([]plugingetter.CompatPlugin, er |
| 188 | 188 |
* bypassing the daemon. For such tests, this check is necessary. |
| 189 | 189 |
*/ |
| 190 | 190 |
if ps != nil {
|
| 191 |
- ps.RLock() |
|
| 192 | 191 |
result = ps.getAllByCap(capability) |
| 193 |
- ps.RUnlock() |
|
| 194 | 192 |
} |
| 195 | 193 |
|
| 196 | 194 |
// Lookup with legacy model |