Fossil SCM
Do not try to uncompress generic HTTP content when the NOCOMPRESS flag is set.
Commit
66ef9061183de74d4959e42669e294cadc01cb3521da3f067a4ce6b1d08a09ad
Parent
8ee8f03a77f23d3…
1 file changed
+3
-3
+3
-3
| --- src/http.c | ||
| +++ src/http.c | ||
| @@ -454,13 +454,13 @@ | ||
| 454 | 454 | isCompressed = 0; |
| 455 | 455 | }else if( fossil_strnicmp(&zLine[14], |
| 456 | 456 | "application/x-fossil-uncompressed", -1)==0 ){ |
| 457 | 457 | isCompressed = 0; |
| 458 | 458 | }else{ |
| 459 | - if( (mHttpFlags & HTTP_GENERIC)==0 | |
| 460 | - && fossil_strnicmp(&zLine[14], "application/x-fossil", -1)!=0 | |
| 461 | - ){ | |
| 459 | + if( mHttpFlags & HTTP_GENERIC ){ | |
| 460 | + if( mHttpFlags & HTTP_NOCOMPRESS ) isCompressed = 0; | |
| 461 | + }else if( fossil_strnicmp(&zLine[14], "application/x-fossil", -1)!=0 ){ | |
| 462 | 462 | isError = 1; |
| 463 | 463 | } |
| 464 | 464 | } |
| 465 | 465 | } |
| 466 | 466 | } |
| 467 | 467 |
| --- src/http.c | |
| +++ src/http.c | |
| @@ -454,13 +454,13 @@ | |
| 454 | isCompressed = 0; |
| 455 | }else if( fossil_strnicmp(&zLine[14], |
| 456 | "application/x-fossil-uncompressed", -1)==0 ){ |
| 457 | isCompressed = 0; |
| 458 | }else{ |
| 459 | if( (mHttpFlags & HTTP_GENERIC)==0 |
| 460 | && fossil_strnicmp(&zLine[14], "application/x-fossil", -1)!=0 |
| 461 | ){ |
| 462 | isError = 1; |
| 463 | } |
| 464 | } |
| 465 | } |
| 466 | } |
| 467 |
| --- src/http.c | |
| +++ src/http.c | |
| @@ -454,13 +454,13 @@ | |
| 454 | isCompressed = 0; |
| 455 | }else if( fossil_strnicmp(&zLine[14], |
| 456 | "application/x-fossil-uncompressed", -1)==0 ){ |
| 457 | isCompressed = 0; |
| 458 | }else{ |
| 459 | if( mHttpFlags & HTTP_GENERIC ){ |
| 460 | if( mHttpFlags & HTTP_NOCOMPRESS ) isCompressed = 0; |
| 461 | }else if( fossil_strnicmp(&zLine[14], "application/x-fossil", -1)!=0 ){ |
| 462 | isError = 1; |
| 463 | } |
| 464 | } |
| 465 | } |
| 466 | } |
| 467 |