.. | .. |
---|
75 | 75 | } |
---|
76 | 76 | |
---|
77 | 77 | /* |
---|
78 | | - * Handle decode buffer overflows out-of-line. |
---|
79 | | - */ |
---|
80 | | -static void print_overflow_msg(const char *func, const struct xdr_stream *xdr) |
---|
81 | | -{ |
---|
82 | | - dprintk("lockd: %s prematurely hit the end of our receive buffer. " |
---|
83 | | - "Remaining buffer length is %tu words.\n", |
---|
84 | | - func, xdr->end - xdr->p); |
---|
85 | | -} |
---|
86 | | - |
---|
87 | | - |
---|
88 | | -/* |
---|
89 | 78 | * Encode/decode NLMv4 basic data types |
---|
90 | 79 | * |
---|
91 | 80 | * Basic NLMv4 data types are defined in Appendix II, section 6.1.4 |
---|
.. | .. |
---|
176 | 165 | dprintk("NFS: returned cookie was too long: %u\n", length); |
---|
177 | 166 | return -EIO; |
---|
178 | 167 | out_overflow: |
---|
179 | | - print_overflow_msg(__func__, xdr); |
---|
180 | 168 | return -EIO; |
---|
181 | 169 | } |
---|
182 | 170 | |
---|
.. | .. |
---|
236 | 224 | __func__, be32_to_cpup(p)); |
---|
237 | 225 | return -EIO; |
---|
238 | 226 | out_overflow: |
---|
239 | | - print_overflow_msg(__func__, xdr); |
---|
240 | 227 | return -EIO; |
---|
241 | 228 | } |
---|
242 | 229 | |
---|
.. | .. |
---|
309 | 296 | out: |
---|
310 | 297 | return error; |
---|
311 | 298 | out_overflow: |
---|
312 | | - print_overflow_msg(__func__, xdr); |
---|
313 | 299 | return -EIO; |
---|
314 | 300 | } |
---|
315 | 301 | |
---|