mirror of
https://github.com/curl/curl.git
synced 2026-01-26 15:03:21 +00:00
openldap: improve check for receiving blank data
It can't access the first byte either unless it has length. Followup to 232d5a2ed9c091c88e3b724a1e7d6 Closes #18632
This commit is contained in:
parent
66d6075af9
commit
979366a625
@ -1171,8 +1171,8 @@ static CURLcode oldap_recv(struct Curl_easy *data, int sockindex, char *buf,
|
||||
|
||||
if(!binary) {
|
||||
/* check for leading or trailing whitespace */
|
||||
if(ISBLANK(bvals[i].bv_val[0]) ||
|
||||
(bvals[i].bv_len &&
|
||||
if(bvals[i].bv_len &&
|
||||
(ISBLANK(bvals[i].bv_val[0]) ||
|
||||
ISBLANK(bvals[i].bv_val[bvals[i].bv_len - 1])))
|
||||
binval = TRUE;
|
||||
else {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user