Modify

Opened 3 years ago

Closed 3 years ago

#10529 closed Bugs (fixed)

The pthread/condition_variable_any constructor reports incorrect error code for pthread_cond_init

Reported by: Boguslaw Sluka <zen77@…> Owned by: viboes
Milestone: Boost 1.57.0 Component: thread
Version: Boost 1.56.0 Severity: Problem
Keywords: Cc:

Description

Constructor of condition_variable_any in pthread implementation reports error in the following way:

 int const res2=pthread_cond_init(&cond,NULL);
            if(res2)
            {
                BOOST_VERIFY(!pthread_mutex_destroy(&internal_mutex));
                boost::throw_exception(thread_resource_error(res, "boost::condition_variable_any::condition_variable_any() failed in pthread_cond_init"));
            }

The thread_resource_error shall use res2 instead of res.

Attachments (1)

patch.txt (329 bytes) - added by Boguslaw Sluka <zen77@…> 3 years ago.

Download all attachments as: .zip

Change History (5)

Changed 3 years ago by Boguslaw Sluka <zen77@…>

Attachment: patch.txt added

comment:1 Changed 3 years ago by Boguslaw Sluka <zen77@…>

boost\thread\pthread\condition_variable.hpp

comment:2 Changed 3 years ago by Boguslaw Sluka <zen77@…>

Component: Nonethread
Owner: set to Anthony Williams

comment:3 Changed 3 years ago by viboes

Milestone: To Be DeterminedBoost 1.57.0
Owner: changed from Anthony Williams to viboes
Status: newassigned

Thanks for catching this.

comment:4 Changed 3 years ago by viboes

Resolution: fixed
Status: assignedclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain viboes.
The resolution will be deleted.

Add Comment


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

 
Note: See TracTickets for help on using tickets.