Stream::Send fixes: doc + StreamConstPtr byte-by-byte + missing SSL availableForWrite by d-a-v · Pull Request #7935 · esp8266/Arduino

Conversation

@d-a-v

Should fix #7928

In the following code

        //if (_byteAddressable)
        //    return _peekPointer < _size ? _buffer[_peekPointer++] : -1;
        return _peekPointer < _size ? pgm_read_byte(&_buffer[_peekPointer++]) : -1;

I wonder if it is worth uncommenting the two first lines, which are valid.

@d-a-v d-a-v mentioned this pull request

Mar 23, 2021

@earlephilhower

I wonder if it is worth uncommenting the two first lines, which are valid.

I'd say no. Code size increase and pgm_read_byte is only 4 insns extra, anyway, so performance vs. the virtual call overhead should be nothing.

@d-a-v d-a-v changed the title StreamConstPtr: fix doc + reading flash space byte-by-byte Stream::Send fixes: doc + StreamConstPtr byte-by-byte + missing SSL availableForWrite

Mar 25, 2021

earlephilhower

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

2 participants

@d-a-v @earlephilhower