[Boost-bugs] [Boost C++ Libraries] #9292: event_log example crashes.

Subject: [Boost-bugs] [Boost C++ Libraries] #9292: event_log example crashes.
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-10-23 00:22:58


#9292: event_log example crashes.
------------------------------+---------------------
 Reporter: mike.ferrel@… | Owner: andysem
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: log
  Version: Boost 1.54.0 | Severity: Problem
 Keywords: |
------------------------------+---------------------
 In supplied event_log_messages.mc:

 SeverityNames=(Debug=0x0:MY_SEVERITY_DEBUG
             Info=0x1:MY_SEVERITY_INFO
             Warning=0x2:MY_SEVERITY_WARNING
             Error=0x3:MY_SEVERITY_ERROR
             )

 Which translates into:

 //
 // Define the severity codes
 //
 #define MY_SEVERITY_WARNING 0x2
 #define MY_SEVERITY_INFO 0x0
 #define MY_SEVERITY_ERROR 0x3

 in the generated event_log_messages.h

 When trying to execute the code:

     type_mapping[error] =
 sinks::event_log::make_event_type(MY_SEVERITY_ERROR);

 in supplied main.cpp

 the call to make_event_type throws out_of_range, because only levels 0, 1,
 2, and 4 are allowed.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/9292>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:14 UTC