mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-11-01 19:17:58 +00:00
Fix possible nil pointer dereference (#13318)
This commit is contained in:
3
changelog/13318.txt
Normal file
3
changelog/13318.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
```release-note:bug
|
||||||
|
identity: Fix possible nil pointer dereference.
|
||||||
|
```
|
||||||
@@ -250,8 +250,9 @@ func (i *IdentityStore) Invalidate(ctx context.Context, key string) {
|
|||||||
// storage entry is non-nil, its an indication of an update. In this
|
// storage entry is non-nil, its an indication of an update. In this
|
||||||
// case, entities in the updated bucket needs to be reinserted into
|
// case, entities in the updated bucket needs to be reinserted into
|
||||||
// MemDB.
|
// MemDB.
|
||||||
entityIDs := make([]string, 0, len(bucket.Items))
|
var entityIDs []string
|
||||||
if bucket != nil {
|
if bucket != nil {
|
||||||
|
entityIDs = make([]string, 0, len(bucket.Items))
|
||||||
for _, item := range bucket.Items {
|
for _, item := range bucket.Items {
|
||||||
entity, err := i.parseEntityFromBucketItem(ctx, item)
|
entity, err := i.parseEntityFromBucketItem(ctx, item)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|||||||
Reference in New Issue
Block a user