---
id: CVE-2022-49107
title: |-
  In the Linux kernel, the following vulnerability has been resolved:

  ceph: fix memory leak in ceph_readdir when note_last_dentry returns error

  Reset the last_readdir at the same time, and add a comment explaining
  why we don't free last_…
summary: |-
  In the Linux kernel, the following vulnerability has been resolved:

  ceph: fix memory leak in ceph_readdir when note_last_dentry returns error

  Reset the last_readdir at the same time, and add a comment explaining
  why we don't free last_…
severity: medium
cvss: 5.5
cvssVector: 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H'
cwe:
  - CWE-401
  - CWE-401
vendor: linux
product: linux_kernel
affected:
  - linux_kernel < 5.10.111
  - 'linux_kernel >= 5.11, < 5.15.34'
  - 'linux_kernel >= 5.16, < 5.16.20'
  - 'linux_kernel >= 5.17, < 5.17.3'
patched:
  - linux_kernel 5.17.3
published: '2025-02-26'
updated: '2026-08-13'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2022-49107'
references:
  - url: 'https://git.kernel.org/stable/c/2fe82d3254029ef9ec4e7be890125d5ef4f537de'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/7f740ede35132d3d5d19747cad56a511d21bb156'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/e792575b902a3939ca482491ee9fb3a236f99640'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/f4429786129648a8f4bb1e5faa143c4478cc5c4a'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/f639d9867eea647005dc824e0e24f39ffc50d4e4'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
tags:
  - nvd
epss: 0.00251
epssPercentile: 0.1469
ingestedAt: '2026-08-13T00:57:22.347Z'
---

## Overview

In the Linux kernel, the following vulnerability has been resolved:

ceph: fix memory leak in ceph_readdir when note_last_dentry returns error

Reset the last_readdir at the same time, and add a comment explaining
why we don't free last_readdir when dir_emit returns false.

## Affected

- `linux_kernel < 5.10.111`
- `linux_kernel >= 5.11, < 5.15.34`
- `linux_kernel >= 5.16, < 5.16.20`
- `linux_kernel >= 5.17, < 5.17.3`

## Remediation

Upgrade past the affected range:

- `linux_kernel 5.17.3`
