mirror of
https://github.com/boostorg/beast.git
synced 2025-07-30 12:57:31 +02:00
Fix costly potential value-init in parser
This commit is contained in:
@ -3,6 +3,8 @@ Version 66:
|
||||
* string_param optimizations
|
||||
* Add serializer request/response aliases
|
||||
* Make consuming_buffers smaller
|
||||
* Fix costly potential value-init in parser
|
||||
* Fix unused parameter warning
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
@ -119,6 +119,7 @@ template<
|
||||
CharT*
|
||||
raw_to_string(CharT* last, std::size_t size, Integer i)
|
||||
{
|
||||
boost::ignore_unused(size);
|
||||
BOOST_ASSERT(size >= max_digits(sizeof(Integer)));
|
||||
return raw_to_string<CharT, Integer, Traits>(
|
||||
last, i, std::is_signed<Integer>{});
|
||||
|
@ -67,7 +67,12 @@ public:
|
||||
message<isRequest, Body, basic_fields<Allocator>>;
|
||||
|
||||
/// Constructor (default)
|
||||
parser() = default;
|
||||
parser()
|
||||
{
|
||||
// avoid `parser()=default` otherwise value-init
|
||||
// for members can happen (i.e. a big memset on
|
||||
// static_buffer_n).
|
||||
}
|
||||
|
||||
/// Copy constructor (disallowed)
|
||||
parser(parser const&) = delete;
|
||||
|
Reference in New Issue
Block a user