[PATCH 4/8] score: Improve _CORE_message_queue_Initialize()
Sebastian Huber
sebastian.huber at embedded-brains.de
Fri Sep 25 04:32:55 UTC 2020
On 24/09/2020 18:39, Gedare Bloom wrote:
>> + status = _CORE_message_queue_Initialize(
>> + &the_mq->Message_queue,
>> + CORE_MESSAGE_QUEUE_DISCIPLINES_FIFO,
>> + attr->mq_maxmsg,
>> + attr->mq_msgsize
>> + );
>> +
>> + if ( status != STATUS_SUCCESSFUL ) {
>> _POSIX_Message_queue_Free( the_mq );
>> _Workspace_Free( name );
>> rtems_set_errno_and_return_value( ENOSPC, MQ_OPEN_FAILED );
> translate the status in case we end up using something besides ENOSPC?
>
I checked the standard and there is no explicit error condition listed
for sizes which lead to an integer overflow. If you do the calculations
with real integers, then you can say, that a 4GB address space system
has insufficient space for the creation of the new message queue needing
5GB.
More information about the devel
mailing list