Modify

Opened 6 years ago

Closed 6 years ago

#6185 closed Bugs (fixed)

_SCL_SECURE_NO_WARNINGS macro redefinition in Boost.Move

Reported by: a.tinsmith@… Owned by: igaztanaga
Milestone: To Be Determined Component: move
Version: Boost 1.48.0 Severity: Regression
Keywords: _SCL_SECURE_NO_WARNINGS C4005 Cc:

Description

In the "boost/move/move.hpp" (line 28) header file _SCL_SECURE_NO_WARNINGS macro is defined without checking whether previous definition exists:

#ifdef BOOST_MSVC
   #ifndef _CRT_SECURE_NO_DEPRECATE
   #define  BOOST_INTERPROCESS_CRT_SECURE_NO_DEPRECATE
   #define _CRT_SECURE_NO_DEPRECATE
   #define _SCL_SECURE_NO_WARNINGS
   #endif
   #pragma warning (push)
   #pragma warning(disable:4996)
#endif

Correct code:

#ifdef BOOST_MSVC
   #ifndef _CRT_SECURE_NO_DEPRECATE
   #define  BOOST_INTERPROCESS_CRT_SECURE_NO_DEPRECATE
   #define _CRT_SECURE_NO_DEPRECATE
   #endif
   #ifndef _SCL_SECURE_NO_WARNINGS
   #define _SCL_SECURE_NO_WARNINGS
   #endif
   #pragma warning (push)
   #pragma warning(disable:4996)
#endif

Attachments (0)

Change History (3)

comment:1 follow-up: Changed 6 years ago by Olaf van der Spek <olafvdspek@…>

IMO the severity should be a bit higher. This produces lots of warnings.

comment:2 in reply to: ↑ 1 Changed 6 years ago by anonymous

  • Severity changed from Problem to Regression

Replying to Olaf van der Spek <olafvdspek@…>:

IMO the severity should be a bit higher. This produces lots of warnings.

comment:3 Changed 6 years ago by igaztanaga

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in trunk

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain igaztanaga.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.