diff options
Diffstat (limited to 'net/9p/client.c')
-rw-r--r-- | net/9p/client.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/9p/client.c b/net/9p/client.c index ea79ee9a7348..f5feac4ff4ec 100644 --- a/net/9p/client.c +++ b/net/9p/client.c | |||
@@ -2101,6 +2101,10 @@ int p9_client_readdir(struct p9_fid *fid, char *data, u32 count, u64 offset) | |||
2101 | trace_9p_protocol_dump(clnt, req->rc); | 2101 | trace_9p_protocol_dump(clnt, req->rc); |
2102 | goto free_and_error; | 2102 | goto free_and_error; |
2103 | } | 2103 | } |
2104 | if (rsize < count) { | ||
2105 | pr_err("bogus RREADDIR count (%d > %d)\n", count, rsize); | ||
2106 | count = rsize; | ||
2107 | } | ||
2104 | 2108 | ||
2105 | p9_debug(P9_DEBUG_9P, "<<< RREADDIR count %d\n", count); | 2109 | p9_debug(P9_DEBUG_9P, "<<< RREADDIR count %d\n", count); |
2106 | 2110 | ||