summaryrefslogtreecommitdiff
path: root/nsswitch/libwbclient
diff options
context:
space:
mode:
Diffstat (limited to 'nsswitch/libwbclient')
-rw-r--r--nsswitch/libwbclient/wb_reqtrans.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/nsswitch/libwbclient/wb_reqtrans.c b/nsswitch/libwbclient/wb_reqtrans.c
index 5328423b15..6dc429bb7d 100644
--- a/nsswitch/libwbclient/wb_reqtrans.c
+++ b/nsswitch/libwbclient/wb_reqtrans.c
@@ -84,6 +84,11 @@ static ssize_t wb_req_more(uint8_t *buf, size_t buflen, void *private_data)
return sizeof(struct winbindd_request) - 4;
}
+ if (buflen > sizeof(struct winbindd_request)) {
+ /* We've been here, we're done */
+ return 0;
+ }
+
if ((state->max_extra_data != 0)
&& (req->extra_len > state->max_extra_data)) {
DEBUG(3, ("Got request with %d bytes extra data on "