masaori335 opened a new issue #7487:
URL: https://github.com/apache/trafficserver/issues/7487


   @bneradt noticed the master branch has a build issue after 
1baffec5f2d5ce5272c9af5d46b2b54f4b9bbe6a.
   ```
   In file included from ProxyProtocol.cc:29:
   In member function ‘virtual ts::FixedBufferWriter& 
ts::FixedBufferWriter::write(const void*, size_t)’,
       inlined from ‘size_t {anonymous}::proxy_protocol_v1_build(uint8_t*, 
size_t, const ProxyProtocol&)’ at ProxyProtocol.cc:341:34,
       inlined from ‘size_t proxy_protocol_build(uint8_t*, size_t, const 
ProxyProtocol&, ProxyProtocolVersion)’ at ProxyProtocol.cc:492:34:
   ../../include/tscore/BufferWriter.h:264:20: error: ‘void* memcpy(void*, 
const void*, size_t)’ forming offset [47, 94] is out of the bounds [0, 46] of 
object ‘src_ip_buf’ with type ‘char [46]’ [-Werror=array-bounds]
            std::memcpy(_buf + _attempted, data, _capacity - _attempted);
            ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   ProxyProtocol.cc: In function ‘size_t proxy_protocol_build(uint8_t*, size_t, 
const ProxyProtocol&, ProxyProtocolVersion)’:
   ProxyProtocol.cc:337:8: note: ‘src_ip_buf’ declared here
      char src_ip_buf[INET6_ADDRSTRLEN];
           ^~~~~~~~~~
   ```
   
   - CentOS7 & devtoolset-8
   
   FWIW, our CentOS 7 build for the master branch is using devtoolset-7.
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to