* [ECOS] sem_getvalue
@ 2001-04-16 6:41 Boris V. Guzhov
0 siblings, 0 replies; only message in thread
From: Boris V. Guzhov @ 2001-04-16 6:41 UTC (permalink / raw)
To: ecos-discuss
Hi,
I use shapshot April 5 2001.
In packages/compat/posix/current/src/sem.cxx file
there is function:
externC int sem_getvalue (sem_t *sem, int *sval)
{
int retval;
SEMA_ENTRY();
Cyg_Counting_Semaphore *sema = (Cyg_Counting_Semaphore *)sem;
retval = sema->peek();
CYG_REPORT_RETVAL( retval );
return retval;
}
I think that it wrong.
And the following is correct:
externC int sem_getvalue (sem_t *sem, int *sval)
{
int retval;
SEMA_ENTRY();
Cyg_Counting_Semaphore *sema = (Cyg_Counting_Semaphore *)sem;
*sval = sema->peek();
CYG_REPORT_RETVAL( retval );
return 0;
}
That's right?
--
Boris Guzhov,
St.Petersburg, Russia
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2001-04-16 6:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-04-16 6:41 [ECOS] sem_getvalue Boris V. Guzhov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).