From fc660b3027141223faeea8dc33ee2003f4b2da9b Mon Sep 17 00:00:00 2001 From: Jeff Hill Date: Tue, 16 Jun 1998 00:25:31 +0000 Subject: [PATCH] cleanup --- src/ca/acctst.c | 76 +++++++++++++++++++++---------------------------- 1 file changed, 33 insertions(+), 43 deletions(-) diff --git a/src/ca/acctst.c b/src/ca/acctst.c index ed2149f26..9290025d2 100644 --- a/src/ca/acctst.c +++ b/src/ca/acctst.c @@ -7,6 +7,9 @@ static char *sccsId = "@(#) $Id$"; /* * $Log$ + * Revision 1.52 1998/05/05 16:03:10 jhill + * use epicsAssert.h + * * Revision 1.51 1998/04/15 21:50:26 jhill * added array as string test * @@ -374,47 +377,32 @@ int doacctst(char *pname) if (ca_state(chix1)==cs_never_conn) { status = ca_pend_io(1e-16); if (status==ECA_TIMEOUT) { - /* - * under vxWorks another thread may connect the - * channel before this gets a chance to run - */ -#ifndef vxWorks - assert(ca_state(chix1)==cs_never_conn); -#endif - printf("waiting on pend io verify connect..."); - fflush(stdout); + + printf ("waiting on pend io verify connect..."); + fflush (stdout); while (ca_state(chix1)!=cs_conn) { ca_pend_event(0.1); } - printf("done\n"); + printf ("done\n"); /* * we end up here if the channel isnt on the same host */ - status = ca_search_and_connect(pname, &chix2, NULL, NULL); - SEVCHK(status, NULL); + status = ca_search_and_connect (pname, &chix2, NULL, NULL); + SEVCHK (status, NULL); status = ca_pend_io(1e-16); - if (status==ECA_TIMEOUT) { - /* - * under vxWorks another thread may connect the - * channel before this gets a chance to run - */ -#ifndef vxWorks - assert(ca_state(chix2)==cs_never_conn); -#endif - } - else { + if (status!=ECA_TIMEOUT) { assert(ca_state(chix2)==cs_conn); } - status = ca_clear_channel(chix2); - SEVCHK(status, NULL); + status = ca_clear_channel (chix2); + SEVCHK (status, NULL); } else { - assert(ca_state(chix1)==cs_conn); + assert (ca_state(chix1)==cs_conn); } } status = ca_clear_channel(chix1); - SEVCHK(status, NULL); + SEVCHK (status, NULL); /* * verify connection handlers are working @@ -513,8 +501,8 @@ int doacctst(char *pname) dbr_float_t base; unsigned long iter; - printf ("float test ..."); - fflush(stdout); + printf ("float test "); + fflush (stdout); epsil = FLT_EPSILON*4.0F; base = FLT_MIN; for (i=FLT_MIN_EXP; i