mirror of
https://github.com/curl/curl.git
synced 2026-08-26 15:13:34 +03:00
upload: Avoid infinite loop when checking for auth bits
The test would loop forever if authtype bit 0 wasn't set.
This commit is contained in:
parent
915032ea02
commit
e7743aa7b4
1 changed files with 1 additions and 1 deletions
|
|
@ -4925,7 +4925,7 @@ operate(struct Configurable *config, int argc, argv_item_t argv[])
|
|||
int authbits = 0;
|
||||
int bitcheck = 0;
|
||||
while(bitcheck < 32) {
|
||||
if(config->authtype & (1 << bitcheck)) {
|
||||
if(config->authtype & (1 << bitcheck++)) {
|
||||
authbits++;
|
||||
if(authbits > 1) {
|
||||
/* more than one, we're done! */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue