Fwd: rt_malloc problem

Paolo Mantegazza mantegazza at aero.polimi.it
Wed Dec 1 19:48:35 CET 2004


Dario Dallefrate wrote:
>>You lost the possibility of submitting a bug fix yourself. 
> 
> 
> No problem, there will be other bugs in the future :-)
> 

For sure.

> 
>>Just a
>>printing more and you would have discovered that msg_size is declared as
>>a char, so the msg_size+ headrsize cannot be greater than 127.
>>I've checkd that it is in the original kernel only version so it is
>>likely an uncheked constraint in its original authors' mind.
>>
>>Set the declaration of msg_size to int and go on too see if it is OK.
>>Report back for a possible fix.
>>
>>Paolo.
>>
> 
> 
> Thank you, now, as you can see, it works
> 
> 
> RTAI Posix Queue Status
> -----------------------
> 
> MAX_PQUEUES =  4 (system wide)
> MQ_OPEN_MAX =  8 (per RT task)
> MQ_NAME_MAX = 80
> 
> ID  NOpen  NMsgs  MaxMsgs  MaxSz  Perms  Del  Name
> --------------------------------------------------------------------------------
> 1   1      0      100      140    0           my_queue1
> 
> This is the only change between the new $RTAI_ROOT/rtai-core/ipc/mq/mq.c e the 
> vesuvio one
> 
> 520c520
> < int msg_size;
> ---
> 
>>char msg_size;
> 

Meanwhile I discovered an "unsigned char msg_size" also. I'll fix them 
both and commit.

Thanks

Paolo.





More information about the Rtai mailing list