This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
Re: pthread_kill return value
- From: Bart Veer <bartv at ecoscentric dot com>
- To: Jay Foster <jay at systech dot com>
- Cc: ecos-discuss at sources dot redhat dot com
- Date: Mon, 08 Feb 2010 12:36:34 +0000
- Subject: Re: [ECOS] pthread_kill return value
- References: <471205.59207.qm@web51906.mail.re2.yahoo.com> <20091019104557.GA19013@sg-ubuntu.local> <964415.68782.qm@web51911.mail.re2.yahoo.com> <20091019135211.GA17646@sg-ubuntu.local> <404723.91676.qm@web51903.mail.re2.yahoo.com> <20091024123837.GA3998@sg-laptop> <738229.12555.qm@web51906.mail.re2.yahoo.com> <20091025132007.GA4436@sg-laptop> <005101ca5622$d9bf4c30$8d3de490$@gellatly@netic.com> <46171.9697145329$1256910809@news.gmane.org> <hcesn2$478$1@ger.gmane.org> <4B6B076C.6020405@systech.com>
>>>>> "Jay" == Jay Foster <jay@systech.com> writes:
Jay> According to the man page for pthread_kill, the return value
Jay> is supposed to be 0 on success and an error number (ESRCH,
Jay> EINVAL) on error. However, the eCos implementation is
Jay> returning 0 on success and -1 on error with errno set to the
Jay> error number. It looks like the eCos pthread_kill() function
Jay> is using the SIGNAL_RETURN() macro when it should be using
Jay> the SIGNAL_RETURN_VALUE() macro.
Jay> Am I reading this correctly?
According to
http://www.opengroup.org/onlinepubs/009695399/functions/pthread_kill.html
the man page is correct. I guess the eCos implementation should be
using SIGNAL_RETURN_VALUE() instead of SIGNAL_RETURN(). A patch would
be welcome. The only use of pthread_kill() in the eCos sources appears
to be in io/fileio, the pselect.c testcase, so that would need fixing
as well.
Bart
--
Bart Veer eCos Configuration Architect
eCosCentric Limited The eCos experts http://www.ecoscentric.com/
Barnwell House, Barnwell Drive, Cambridge, UK. Tel: +44 1223 245571
Registered in England and Wales: Reg No 4422071.
Besuchen Sie uns vom 2-4 März auf der Embedded World 2010, Stand 11-208
Visit us at Embedded World 2010, Nürnberg-Germany, 2-4 Mar, Stand 11-208
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss