Commit 02e3757
ceph: handle zero-length feature mask in session messages
Most session messages contain a feature mask, but the MDS will
routinely send a REJECT message with one that is zero-length.
Commit 0fa8263 ("ceph: fix endianness bug when handling MDS
session feature bits") fixed the decoding of the feature mask,
but failed to account for the MDS sending a zero-length feature
mask. This causes REJECT message decoding to fail.
Skip trying to decode a feature mask if the word count is zero.
Cc: stable@vger.kernel.org
URL: https://tracker.ceph.com/issues/46823
Fixes: 0fa8263 ("ceph: fix endianness bug when handling MDS session feature bits")
Signed-off-by: Jeff Layton <jlayton@kernel.org>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Tested-by: Patrick Donnelly <pdonnell@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>1 parent 224c7b6 commit 02e3757
1 file changed
Lines changed: 4 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3358 | 3358 | | |
3359 | 3359 | | |
3360 | 3360 | | |
3361 | | - | |
3362 | | - | |
| 3361 | + | |
| 3362 | + | |
| 3363 | + | |
| 3364 | + | |
3363 | 3365 | | |
3364 | 3366 | | |
3365 | 3367 | | |
| |||
0 commit comments