Commit 5468c0f
committed
perf/core: Don't leak AUX buffer refcount on allocation failure
Failure of the AUX buffer allocation leaks the reference count.
Set the reference count to 1 only when the allocation succeeds.
Fixes: 45bfb2e ("perf: Add AUX area to ring buffer for raw data streams")
Signed-off-by: Thomas Gleixner <[email protected]>
Reviewed-by: Lorenzo Stoakes <[email protected]>
Cc: [email protected]1 parent 54473e0 commit 5468c0f
1 file changed
Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7051 | 7051 | | |
7052 | 7052 | | |
7053 | 7053 | | |
7054 | | - | |
7055 | | - | |
7056 | 7054 | | |
7057 | 7055 | | |
7058 | 7056 | | |
| |||
7119 | 7117 | | |
7120 | 7118 | | |
7121 | 7119 | | |
7122 | | - | |
| 7120 | + | |
| 7121 | + | |
7123 | 7122 | | |
| 7123 | + | |
7124 | 7124 | | |
7125 | 7125 | | |
7126 | 7126 | | |
| |||
7130 | 7130 | | |
7131 | 7131 | | |
7132 | 7132 | | |
| 7133 | + | |
7133 | 7134 | | |
7134 | 7135 | | |
7135 | 7136 | | |
| |||
0 commit comments