From 45cc78fdbc0e01d744156e853ea80de43d672f2b Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Fri, 19 Oct 2001 06:27:24 +0000 Subject: [PATCH] CURLOPT_FAILONERROR now only returns error if the HTTP code is 400 or above unconditionalliy. Previously, the code check was for >= 300 unless follow- location was enabled... --- lib/transfer.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/lib/transfer.c b/lib/transfer.c index 90033a7bf..bc07aab2b 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -518,13 +518,8 @@ Transfer(struct connectdata *c_conn) data->info.httpversion = httpversion; /* 404 -> URL not found! */ - if ( - ( ((data->set.http_follow_location) && - (httpcode >= 400)) - || - (!data->set.http_follow_location && - (httpcode >= 300))) - && (data->set.http_fail_on_error)) { + if (data->set.http_fail_on_error && + (httpcode >= 400)) { /* If we have been told to fail hard on HTTP-errors, here is the check for that: */ /* serious error, go home! */