Commit Graph

166 Commits

Author SHA1 Message Date
Michael Davidsaver
7acd7c6145 minor epicsTimerTest 2019-11-12 19:07:30 -08:00
Michael Davidsaver
bef9a08f6d asLib minor 2019-11-12 19:07:30 -08:00
Michael Davidsaver
3e7ad9a86f rtems_init cleanup
Remove unnecessary (as of RTEMS 4.9) prototypes
Remove unused *Fatal
constify string contant
2019-11-12 19:07:30 -08:00
Michael Davidsaver
76b9461ee8 logClient windows needs SOCK_E* 2019-11-12 19:07:30 -08:00
Andrew Johnson
220a27bdec Merge Dirk's dynamicVxWorksVmeFunctionBinding branch into 7.0 2019-10-28 15:11:54 -05:00
Andrew Johnson
171b3301a7 Fix ..// => ../ in Makefile-relative source paths 2019-10-28 15:00:15 -05:00
Andrew Johnson
e178fa85b6 Merge 7.0 back into 7.0
Insert tab B back into slot A ...
2019-10-28 13:30:58 -05:00
Michael Davidsaver
5e6226e595 osdSockUnsentCount.c check for existance of SIO_TCP_INFO 2019-10-28 10:06:05 -07:00
Andrew Johnson
3e7e26d8d7 Merge 3.15 branch into 7.0 2019-10-28 01:03:12 -05:00
Michael Davidsaver
fc04d12578 Merge remote-tracking branch 'zimoch/iocLogClientFixesTry2' into 7.0
* zimoch/iocLogClientFixesTry2: (22 commits)
  use EPICS_PRIVATE_API macro and fix bug with darwin/ios
  renamed epicsSocketCountUnsentBytes to epicsSocketUnsentCount and moved it to osi/os/
  fix bug from commit f85454. Apparently epicsExportSharedSymbols is needed even though epicsExport.h is included
  epicsSocketCountUnsentBytes returns -1 on failure
  bugfix: memmove'ed to much
  epicsSockCountUnsentBytes renamed to epicsSocketCountUnsentBytes
  moved logClientSendMessage and made it static
  fix wrong function name in comment
  sending 0 bytes helps to detect broken connections on some systems (but is undefined behavior on Linux, fails on vxWorks and is a documented no-op on Windows)
  cannot print sockets with %d in Windows, they are not small ints but maybe pointers.
  ask logClient socket how many bytes are still in the send queue and don't discard them in case the connection turns out broken.
  use dynamic debug flag for logClient
  increase error message buffer size for long (Windows) error messges
  improve logClientShow to show unsent bytes on level 2 (and fix level 1)
  removed unneeded include
  no need to delay startup only because log server is currently not available
  send pending log messages directly after connecting
  avoid needless memmove calls
  elimitate duplicate code in logClient
  do not discard unsent messages when log server has closed connection, instead try to send them after reconnect
  ...
2019-10-24 10:22:07 -07:00
Michael Davidsaver
f3204d8afa provide default for PATH_MAX 2019-10-20 18:35:55 -07:00
Michael Davidsaver
a34a84f19f libcom: win32 poison TLS value 2019-10-17 20:12:10 -07:00
Freddie Akeroyd
edc66418ac WIN32: Add symbol lookup 2019-10-17 20:10:23 -07:00
Freddie Akeroyd
c8006f2934 WIN32: Add stack trace printing on assert/error 2019-10-17 20:09:37 -07:00
Michael Davidsaver
32aeabfc61 msvc unittests disable dialog on error or assert() failure
Showing a dialog is really unhelpful in headless CI environments.

_CrtSetReportMode also set _CRT_WARN
Not clear what the default is.
2019-10-17 20:09:27 -07:00
Michael Davidsaver
e257e30cc9 Merge remote-tracking branch 'lp-Com/use-monotonic' into 7.0
* lp-Com/use-monotonic:
  VxWorks: Measure CPU time-base frequency if necessary
  replace most internal getCurrent() -> getMonotonic()
  dbScan periodic scan use monotonic time
  monotonic adapt to regular time APIs
2019-10-06 20:10:20 -07:00
Michael Davidsaver
c131d6852d Merge remote-tracking branch 'lp-Com/iocsherr' into 7.0
* lp-Com/iocsherr:
  doc
  deprecate iocshFindCommand()
  iocshTest start
  iocshCmd() imply "on error break"
  iocsh more error handling
  iocsh handle redirect and similar early errors
  iocsh trap arg. parsing errors
  iocsh further on error
  Fixed logic errors and added some prompts.
  use iocshSetError()
  iocsh allow setting of error code
  iocsh control error behavior
  iocsh catch exceptions

# Conflicts:
#	documentation/RELEASE_NOTES.html
2019-10-06 20:10:09 -07:00
Michael Davidsaver
02bec52f0a Merge remote-tracking branch 'lp-make/rpath-origin' into 7.0
* lp-make/rpath-origin:
  makeRPath allow multiple root directories
  redo softIoc to be more c++y
  rpath $ORIGIN doc
  older binutils compat
  travis-ci test rpath $ORIGIN
  epicsGetExecName WIN32, Darwin, solaris, freebsd
  epicsGetExecDir() paths relative to executable
  LINKER_USE_RPATH=ORIGIN

# Conflicts:
#	configure/os/CONFIG.Common.linuxCommon
2019-10-06 20:05:47 -07:00
Michael Davidsaver
8ff7658291 asLib: osiSockAttach() for asCheckClientIP
WIN32 needs osiSockAttach() prior to aToIPAddr()
which can now happen during ACF parsing.
2019-10-06 19:59:33 -07:00
Michael Davidsaver
e83818b25e workaround apparent MSVC mis-optimization
MSVC appears to misapply the identity
"A + -A == 0" which is not true for
non-finite floating point values.
2019-10-06 19:58:23 -07:00
4bb81654d6 use EPICS_PRIVATE_API macro and fix bug with darwin/ios 2019-10-04 14:32:07 +02:00
Michael Davidsaver
17aaf50136 WIN32 must clean TLS from correct thread
epicsParmCleanupWIN32() may be called from
threads other than the one being cleaned up.
2019-09-24 20:36:18 -07:00
Michael Davidsaver
b68f47927c WIN32 remove atexit cleanup of TLS
Force cleanup of resource for threads which may
still be running opens the possibility of strange
race conditions.  Like threads be erroneously
detected as non-epics.

Doing this cleanup at process exit serves no real
purpose.  This code might be valid to re-add
in a DLL exit handler.
2019-09-24 20:21:56 -07:00
Michael Davidsaver
f134abb84e epicsThread avoid possible data race on joined 2019-09-24 08:52:48 -07:00
Freddie Akeroyd
ee1eac3f4c iocshRegisterVariable() takes an array 2019-09-23 18:55:51 -07:00
46912d5516 renamed epicsSocketCountUnsentBytes to epicsSocketUnsentCount and moved it to osi/os/ 2019-09-23 11:10:32 +02:00
cf121f1c14 fix bug from commit f85454. Apparently epicsExportSharedSymbols is needed even though epicsExport.h is included 2019-09-23 10:54:17 +02:00
1718647121 epicsSocketCountUnsentBytes returns -1 on failure 2019-09-19 12:08:45 +02:00
752ec12261 bugfix: memmove'ed to much 2019-09-19 11:42:04 +02:00
e28bb3b0e2 epicsSockCountUnsentBytes renamed to epicsSocketCountUnsentBytes 2019-09-19 10:48:14 +02:00
64f540a64f moved logClientSendMessage and made it static 2019-09-19 10:44:36 +02:00
db3b160f4e fix wrong function name in comment 2019-09-19 08:54:19 +02:00
c9b670977d sending 0 bytes helps to detect broken connections on some systems (but is undefined behavior on Linux, fails on vxWorks and is a documented no-op on Windows) 2019-09-18 09:58:28 +02:00
Michael Davidsaver
966965c2c1 Merge remote-tracking branch 'lp-Com/make-simple' into 7.0
* main/make-simple:
  restore ModuleDirs in caPerlApp
  simplify e_flex/antelope path compute
  further no need to search for perl modules under bin
  skip RELEASE_TOPS
  configure: Don't hide any perl scripts being run
  missed a TOP
  no need to search for perl modules under bin/
  drop unnecessary *ModuleDirs
  avoided embedded TOP for non sub-modules
2019-09-17 14:57:47 -07:00
931054d4fd cannot print sockets with %d in Windows, they are not small ints but maybe pointers. 2019-09-17 17:45:33 +02:00
6ffc9e17da ask logClient socket how many bytes are still in the send queue and don't discard them in case the connection turns out broken. 2019-09-17 17:34:16 +02:00
f85454a8d6 use dynamic debug flag for logClient 2019-09-17 17:12:58 +02:00
26f6f674be increase error message buffer size for long (Windows) error messges 2019-09-17 14:41:35 +02:00
d162337b9a improve logClientShow to show unsent bytes on level 2 (and fix level 1) 2019-09-17 14:39:03 +02:00
49bf8bb5ec removed unneeded include 2019-09-17 11:59:02 +02:00
Michael Davidsaver
0f8876de67 Merge branch '3.15' into 7.0
* 3.15: (28 commits)
  update RELEASE_NOTES
  add option EPICS_NO_CALLBACK
  replace CALLBACK -> epicsCallback
  Update dbTest.c
  Remove links to wiki-ext
  Add POD annotations from Wiki to subArrayRecord and menuAlarmStat
  Rename subArrayRecord.dbd and menuAlarmStat.dbd to .pod
  Add POD annotations to longoutRecord from Wiki
  Rename longoutRecord.dbd longoutRecord.dbd.pod
  Add POD annotations to longinRecord from Wiki
  Rename longinRecord.dbd longinRecord.dbd.pod
  Add POD annotations to subRecord from Wiki
  Rename subRecord.dbd subRecord.dbd.pod
  Add POD annotations to selRecord from Wiki
  Rename selRecord.dbd selRecord.dbd.pod
  Add POD annotations to seqRecord from Wiki
  Rename seqRecord.dbd seqRecord.dbd.pod
  Fix menu declaration test too
  Add redefinition guard to menu-generated typedefs
  Updates to existing .dbd.pod texts, add event and fanout from wiki
  ...

# Conflicts:
#	documentation/README.1st
#	documentation/README.html
#	modules/database/src/ioc/db/callback.h
#	modules/database/src/ioc/db/dbNotify.c
#	modules/database/src/ioc/db/menuAlarmStat.dbd
#	modules/database/src/ioc/db/menuFtype.dbd
#	modules/database/src/std/rec/compressRecord.dbd.pod
#	modules/database/src/std/rec/eventRecord.dbd
#	modules/database/src/std/rec/fanoutRecord.dbd
#	modules/database/src/std/rec/longinRecord.dbd
#	modules/database/src/std/rec/longoutRecord.dbd
#	modules/database/src/std/rec/selRecord.dbd
#	modules/database/src/std/rec/seqRecord.dbd
#	modules/database/src/std/rec/subArrayRecord.dbd
#	modules/database/src/std/rec/subRecord.dbd
#	modules/libcom/src/iocsh/menuAlarmStat.dbd.pod
#	modules/libcom/src/iocsh/menuFtype.dbd.pod
#	src/ioc/db/menuAlarmStat.dbd
#	src/ioc/db/menuFtype.dbd

Manually fix some move+rename
Make additional CALLBACK -> epicsCallback
preserve INT64 in menuFtype
preserve OLDSIM et al
2019-09-09 19:29:58 -07:00
Michael Davidsaver
937379892a epicsMutex automatically capture file+line with gcc >=4.8
gcc >=4.8 allows __builtin_FILE() to expand at the call
site when used given as the default for a c++ function
argument.
2019-09-05 19:30:43 -07:00
Michael Davidsaver
c0a04eae21 Merge remote-tracking branch 'lp-asLib/as-hostname' into 7.0
* lp-asLib/as-hostname:
  update release notes
  asLib more string size...
  asLib one short
  asLib: asUseIP name lookup soft-fail
  Expand Release Note entry for as-hostname changes.
  as-hostname address review comments
  asLib: test asUseIP
  as,rsrv: use real client IP instead of untrusted host name

# Conflicts:
#	documentation/RELEASE_NOTES.html
2019-08-31 15:07:22 -07:00
Michael Davidsaver
75477b5e9c Merge remote-tracking branch 'origin/3.15' into 7.0
* origin/3.15: (40 commits)
  Revert "More msi.plt retries for Jenkins builds on Windows"
  Revert "Testing msi: Add retries if necessary"
  msi: Flush stdout on program exit
  Now fix the non-windows systems
  Don't use / in Windows program paths
  Redirect msi's STDERR to /dev/null (NUL on Windows) during tests
  VxWorks: Mark undetected underflow parse test as ToDo
  Fix VxWorks osiSockOptMcastLoop_t => char
  Fix sync filter example in dbd.pod
  doc/ca: clarify variable size array subscription
  Remove cacExitHandler
  Don't clear caClientCallbackThreadId in CA's exit handler
  appveyor-ci: ANL Make install 4.1 -> 4.2.1
  appveyor-ci: use pre-installed AppVeyor MinGW
  appveyor-ci: use choco MinGW 5.3.0 to work around build problem (fixes lp:1827225)
  appveyor-ci: exclude some cygwin builds (broken compiler) appveyor-ci: remove slack, add email and GitHub notifications (cherry-picked from branch 7.0)
  epicsTime: rely on implicit copy constructor
  iocLogServer: check return values
  Fix potential buffer overflow in iocLogServer
  Fix weird use of strncpy
  ...

# Conflicts:
#	modules/database/src/ioc/dbtemplate/msi.c
#	modules/database/src/std/rec/stringinRecord.c
#	modules/database/src/std/rec/stringoutRecord.c
#	modules/database/test/ioc/dbtemplate/msi.plt
#	modules/libcom/src/osi/os/vxWorks/osdSock.h
#	src/ioc/dbtemplate/msi.c
#	src/ioc/dbtemplate/msi.cpp
2019-08-31 15:05:37 -07:00
2b0161d9bf no need to delay startup only because log server is currently not available 2019-08-30 08:57:08 +02:00
9df98c1838 send pending log messages directly after connecting 2019-08-30 08:57:08 +02:00
59aa9cfe74 avoid needless memmove calls 2019-08-30 08:57:08 +02:00
709208ef5c elimitate duplicate code in logClient 2019-08-30 08:57:08 +02:00
0a3427c835 do not discard unsent messages when log server has closed connection, instead try to send them after reconnect 2019-08-30 08:57:08 +02:00
2432878773 speed up logRestart thread termination at exit 2019-08-30 08:57:08 +02:00