1994 1995 1996 1997 1998 1999 2000 2001 <2002> 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 | Index | 1994 1995 1996 1997 1998 1999 2000 2001 <2002> 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: side-effect of malloc() in startup file |
From: | Korhonen Timo <[email protected]> |
To: | "Peregrine M. McGehee" <[email protected]> |
Cc: | [email protected] |
Date: | Tue, 30 Jul 2002 19:37:20 +0200 |
The vxWorks tShell crashes after calls to both malloc() and
iocInit within a st.cmd have been traced to the drvTS.c TSinit() routine that is called within iocInit. The environment is Power PC; VxWorks 5.4; EPICS R3.13.5 and requires definition
of local synchronized timestamp support routines
(http://www.aps.anl.gov/asd/controls/hideos/GTS.html).
This is a consequence of insufficient (none!) range checking for access within the TSdata.event_table array of struct timespec
allocated in TSinit(). The quick patch is to always have an
ErSyncEvent() function that returns an event number less than
the return value of ErHaveReceiver() when supplying local timestamp support. The harder correction is to rewrite drvTS!
best regards, Timo