Unverified Commit e9d9d1af authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

http: don't set the "rewind" flag when not uploading anything

It triggers an assert.

Detected by OSS-Fuzz
Bug: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=8144
Closes #2546
parent 277d3cdc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -433,7 +433,7 @@ static CURLcode http_perhapsrewind(struct connectdata *conn)
           data left to send, keep on sending. */

        /* rewind data when completely done sending! */
        if(!conn->bits.authneg) {
        if(!conn->bits.authneg && (conn->writesockfd != CURL_SOCKET_BAD)) {
          conn->bits.rewindaftersend = TRUE;
          infof(data, "Rewind stream after send\n");
        }