conn.c
This commit is contained in:
@@ -48,7 +48,7 @@ PROD := caRepeater
|
||||
PROD_LIBS := ca Com
|
||||
SYS_PROD_LIBS_WIN32 := ws2_32 user32 advapi32
|
||||
|
||||
TESTPROD := catime acctst
|
||||
TESTPROD := catime acctst connTest
|
||||
|
||||
include $(TOP)/config/RULES.Host
|
||||
|
||||
|
||||
+5
-5
@@ -1707,7 +1707,7 @@ void dbr_ntohf(dbr_float_t *pNet, dbr_float_t *pHost)
|
||||
|
||||
#endif /*CA_FLOAT_MIT*/
|
||||
|
||||
#if defined(CA_FLOAT_IEEE) && 0
|
||||
#if defined(CA_FLOAT_IEEE) && 1
|
||||
|
||||
/*
|
||||
* dbr_htond ()
|
||||
@@ -1716,8 +1716,8 @@ void dbr_ntohf(dbr_float_t *pNet, dbr_float_t *pHost)
|
||||
void dbr_htond (dbr_double_t *IEEEhost, dbr_double_t *IEEEnet)
|
||||
{
|
||||
#ifdef CA_LITTLE_ENDIAN
|
||||
ca_uint32_t *pHost = (ca_uint32_t *) IEEEhost;
|
||||
ca_uint32_t *pNet = (ca_uint32_t *) IEEEnet;
|
||||
ca_uint32_t *pHost = (ca_uint32_t *) IEEEhost;
|
||||
ca_uint32_t *pNet = (ca_uint32_t *) IEEEnet;
|
||||
ca_uint32_t tmp;
|
||||
|
||||
/*
|
||||
@@ -1740,8 +1740,8 @@ void dbr_htond (dbr_double_t *IEEEhost, dbr_double_t *IEEEnet)
|
||||
void dbr_ntohd (dbr_double_t *IEEEnet, dbr_double_t *IEEEhost)
|
||||
{
|
||||
#ifdef CA_LITTLE_ENDIAN
|
||||
ca_uint32_t *pHost = (ca_uint32_t *) IEEEhost;
|
||||
ca_uint32_t *pNet = (ca_uint32_t *) IEEEnet;
|
||||
ca_uint32_t *pHost = (ca_uint32_t *) IEEEhost;
|
||||
ca_uint32_t *pNet = (ca_uint32_t *) IEEEnet;
|
||||
ca_uint32_t tmp;
|
||||
|
||||
/*
|
||||
|
||||
+13
-8
@@ -102,19 +102,22 @@ epicsShareExtern CACVRTFUNC *cac_dbr_cvrt[LAST_BUFFER_TYPE+1];
|
||||
* so we need a tmp variable in e.g. 'double' conversions.
|
||||
*/
|
||||
|
||||
#ifdef CA_LITTLE_ENDIAN
|
||||
#if defined(CA_LITTLE_ENDIAN)
|
||||
#if 0
|
||||
( (dbr_short_t) ((((dbr_ushort_t)SHORT)>>8) | (((dbr_ushort_t)SHORT)<<8))
|
||||
# ifndef ntohs
|
||||
# define ntohs(SHORT)\
|
||||
( (dbr_short_t)\
|
||||
(((SHORT) & (dbr_short_t) 0x00ff) << 8 |\
|
||||
((SHORT) & (dbr_short_t) 0xff00) >> 8) )
|
||||
((((dbr_ushort_t)SHORT) & (dbr_ushort_t) 0x00ff) << 8 |\
|
||||
(((dbr_ushort_t)SHORT) & (dbr_ushort_t) 0xff00) >> 8) )
|
||||
# endif
|
||||
# ifndef htons
|
||||
# define htons(SHORT)\
|
||||
( (dbr_short_t)\
|
||||
(((SHORT) & (dbr_short_t) 0x00ff) << 8 |\
|
||||
((SHORT) & (dbr_short_t) 0xff00) >> 8) )
|
||||
((((dbr_ushort_t)SHORT) & (dbr_ushort_t) 0x00ff) << 8 |\
|
||||
(((dbr_ushort_t)SHORT) & (dbr_ushort_t) 0xff00) >> 8) )
|
||||
# endif
|
||||
#endif
|
||||
#else
|
||||
# ifndef ntohs
|
||||
# define ntohs(SHORT) (SHORT)
|
||||
@@ -125,7 +128,8 @@ epicsShareExtern CACVRTFUNC *cac_dbr_cvrt[LAST_BUFFER_TYPE+1];
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef CA_LITTLE_ENDIAN
|
||||
#if defined(CA_LITTLE_ENDIAN)
|
||||
#if 0
|
||||
# ifndef ntohl
|
||||
# define ntohl(LONG)\
|
||||
( (dbr_long_t) (\
|
||||
@@ -144,7 +148,8 @@ epicsShareExtern CACVRTFUNC *cac_dbr_cvrt[LAST_BUFFER_TYPE+1];
|
||||
( ((dbr_ulong_t)(LONG)) & 0x0000ff00 ) << 8u )\
|
||||
)
|
||||
# endif
|
||||
# else
|
||||
#endif
|
||||
#else
|
||||
# ifndef ntohl
|
||||
# define ntohl(LONG) (LONG)
|
||||
# endif
|
||||
@@ -162,7 +167,7 @@ epicsShareExtern CACVRTFUNC *cac_dbr_cvrt[LAST_BUFFER_TYPE+1];
|
||||
(*(dbr_float_t *)(IEEEnet) = *(dbr_float_t *)(IEEEhost))
|
||||
# define dbr_ntohf(IEEEnet, IEEEhost) \
|
||||
(*(dbr_float_t *)(IEEEhost) = *(dbr_float_t *)(IEEEnet))
|
||||
#elif defined(CA_FLOAT_IEEE) && defined(CA_LITTLE_ENDIAN)
|
||||
#elif defined(CA_FLOAT_IEEE) && defined(CA_LITTLE_ENDIAN) && 0
|
||||
# define dbr_ntohf(NET,HOST) \
|
||||
{*((dbr_long_t *)(HOST)) = ntohl(*((dbr_long_t *)(NET )));}
|
||||
# define dbr_htonf(HOST,NET) \
|
||||
|
||||
@@ -32,6 +32,9 @@
|
||||
* Modification Log:
|
||||
* -----------------
|
||||
* $Log$
|
||||
* Revision 1.41 1998/07/07 23:01:42 jhill
|
||||
* use high precision timers
|
||||
*
|
||||
* Revision 1.40 1998/06/22 22:32:03 jhill
|
||||
* EPICS_DLL => EPICS_DLL_NO (so we are backwards compatible
|
||||
*
|
||||
@@ -76,6 +79,9 @@
|
||||
*
|
||||
* Revision 1.19 1995/11/29 19:15:42 jhill
|
||||
* added $Log$
|
||||
* added Revision 1.41 1998/07/07 23:01:42 jhill
|
||||
* added use high precision timers
|
||||
* added
|
||||
* added Revision 1.40 1998/06/22 22:32:03 jhill
|
||||
* added EPICS_DLL => EPICS_DLL_NO (so we are backwards compatible
|
||||
* added
|
||||
@@ -742,20 +748,25 @@ BOOL epicsShareAPI DllMain (HANDLE hModule, DWORD dwReason, LPVOID lpReserved)
|
||||
}
|
||||
# endif
|
||||
|
||||
#if 0
|
||||
status = ca_task_initialize();
|
||||
if (status!=ECA_NORMAL) {
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
# ifdef _DEBUG
|
||||
fprintf(stderr, "Process attached to ca.dll version %s\n", EPICS_VERSION_STRING);
|
||||
# endif
|
||||
break;
|
||||
|
||||
case DLL_PROCESS_DETACH:
|
||||
#if 0
|
||||
status = ca_task_exit ();
|
||||
if (status!=ECA_NORMAL) {
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
# ifdef _DEBUG
|
||||
fprintf(stderr, "Process detached from ca.dll version %s\n", EPICS_VERSION_STRING);
|
||||
# endif
|
||||
|
||||
Reference in New Issue
Block a user