Menu [hide]

Forum: DCCP-TP

Forums->DCCP-TP->Function Definatin not Found!

gillbrent
Function Definatin not Found!


Hej,

i am looking the code in dctpPthreadsSupport.c i found the function declaration that is "pthread_mutexattr_setkind_np"
and this funcion is also called in "dctpoSocketLockInit " in same file but where does the Defination of function ? is some trick or some thing new which i never used before.

Waitnig for Reply !

Sami Gillbrent

 
on: Sun 18 of May, 2008 [18:43 UTC] reads: 3722

Posted messages

author message
shafi.jawad
Re: Function Definatin not Found!
on: Sun 18 of May, 2008 [19:29 UTC]
> Hej,
>
> i am looking the code in dctpPthreadsSupport.c i found the function declaration that is "pthread_mutexattr_setkind_np"
> and this funcion is also called in "dctpoSocketLockInit " in same file but where does the Defination of function ? is some trick or some thing new which i never used before.
>
> Waitnig for Reply !
>
> Sami Gillbrent
_
Hi Sami,

the question oyu r asking that theanswer is the pthread Standared functin and if you google it you will found the descreption of
"pthread_mutexattr_setkind_np" the defiantion and details any how i am poiting you towards
http://publib.boulder.ibm.com/iseries/v5r1/ic2924/index.htm?info/apis/users_55.htm
http://node1.yo-linux.com/cgi-bin/man2html?cgi_command=pthread_mutexattr_setkind_np

and your second question is valid that is the Tom as written the Decleration/ProtoType if its already part of pthread the Answer is simply i do not know why he done this question its question for me but i thought the Tom will tell you more breifly about that.

GOOD LUCK!

Regards
Jawad Shafi.


author message
trphelan
Re: Function Definatin not Found!
on: Sun 18 of May, 2008 [21:48 UTC]
Hi Sami,

As Jawad said, pthread_mutexattr_setkind_np is part of the standard Pthread package (if you have access to a Linux system see 'man pthread_mutexattr_setkind_np'). But for some reason on my Linux system, it doesn't seem to be defined in pthread.h, even though it's in the pthread library, so I added the definition to dctpPthreadsSupport.c. Since it's actually only needed when you've defined DEBUG, I figured it was an OK workaround.

Tom P.


author message
gillbrent
Re: Function Definatin not Found!
on: Mon 19 of May, 2008 [13:49 UTC]
> Hej,
>
> i am looking the code in dctpPthreadsSupport.c i found the function declaration that is "pthread_mutexattr_setkind_np"
> and this funcion is also called in "dctpoSocketLockInit " in same file but where does the Defination of function ? is some trick or some thing new which i never used before.
>
> Waitnig for Reply !
>
> Sami Gillbrent



HI GUYS!

Thansk alot jawad and Tom for putting your answers

Sami G.




Show posts: