|
From: Ned K. <ne...@us...> - 2003-11-21 02:40:21
|
Update of /cvsroot/squeak/squeak/platforms/unix/vm
In directory sc8-pr-cvs1:/tmp/cvs-serv26458/unix/vm
Modified Files:
Tag: ned-branch
sqUnixExternalPrims.c sqUnixMain.c
Log Message:
Copied from Ian's 3.6g-2 sources, with recent patches by Ned Konz
Index: sqUnixExternalPrims.c
===================================================================
RCS file: /cvsroot/squeak/squeak/platforms/unix/vm/sqUnixExternalPrims.c,v
retrieving revision 1.11
retrieving revision 1.11.2.1
diff -C2 -d -r1.11 -r1.11.2.1
*** sqUnixExternalPrims.c 3 Sep 2003 18:08:23 -0000 1.11
--- sqUnixExternalPrims.c 21 Nov 2003 02:40:18 -0000 1.11.2.1
***************
*** 37,48 ****
/* Author: Ian...@IN...
*
! * Last edited: 2003-09-03 18:06:25 by piumarta on emilia.inria.fr
*/
- #define DEBUG 0
-
#include "sq.h" /* sqUnixConfig.h */
! #if DEBUG
# define dprintf(ARGS) fprintf ARGS
#else
--- 37,46 ----
/* Author: Ian...@IN...
*
! * Last edited: 2003-09-07 15:38:59 by piumarta on emilia.inria.fr
*/
#include "sq.h" /* sqUnixConfig.h */
! #if defined(DEBUG) && DEBUG>0
# define dprintf(ARGS) fprintf ARGS
#else
***************
*** 305,309 ****
int ioFindExternalFunctionIn(char *lookupName, int moduleHandle)
{
! void *fn= dlsym((void *)moduleHandle, lookupName);
dprintf((stderr, "ioFindExternalFunctionIn(%s, %d)\n",
--- 303,316 ----
int ioFindExternalFunctionIn(char *lookupName, int moduleHandle)
{
! char buf[256];
! void *fn;
!
! #ifdef HAVE_SNPRINTF
! snprintf(buf, sizeof(buf), "%s", lookupName);
! #else
! sprintf(buf, "%s", lookupName);
! #endif
!
! fn= dlsym((void *)moduleHandle, buf);
dprintf((stderr, "ioFindExternalFunctionIn(%s, %d)\n",
***************
*** 312,315 ****
--- 319,323 ----
if ((fn == 0) && (!sqIgnorePluginErrors)
&& strcmp(lookupName, "initialiseModule")
+ && strcmp(lookupName, "shutdownModule")
&& strcmp(lookupName, "setInterpreter")
&& strcmp(lookupName, "getModuleName"))
Index: sqUnixMain.c
===================================================================
RCS file: /cvsroot/squeak/squeak/platforms/unix/vm/sqUnixMain.c,v
retrieving revision 1.13
retrieving revision 1.13.2.1
diff -C2 -d -r1.13 -r1.13.2.1
*** sqUnixMain.c 3 Sep 2003 18:07:35 -0000 1.13
--- sqUnixMain.c 21 Nov 2003 02:40:18 -0000 1.13.2.1
***************
*** 68,74 ****
#endif
#undef DEBUG_MODULES
! #undef IMAGE_DUMP /* define to enable SIGHUP and SIGQUIT handling */
#define IMAGE_NAME_SIZE MAXPATHLEN
--- 68,79 ----
#endif
+ /*
#undef DEBUG_MODULES
+ */
! /* define to enable SIGHUP and SIGQUIT handling */
! /*
! #undef IMAGE_DUMP
! */
#define IMAGE_NAME_SIZE MAXPATHLEN
***************
*** 453,462 ****
{
int nwt= getNextWakeupTick();
- int now= (ioMSecs() & 0x1fffffff);
int ms= 0;
! if (nwt <= now)
! ms= (nwt ? 0 : (1000/60));
! else
! ms= nwt - now;
if (ms < (1000/60)) /* < 1 timeslice? */
{
--- 458,469 ----
{
int nwt= getNextWakeupTick();
int ms= 0;
!
! if (nwt)
! {
! int now= (ioMSecs() & 0x1fffffff);
! ms= ((nwt <= now) ? (1000/60) : nwt - now);
! }
!
if (ms < (1000/60)) /* < 1 timeslice? */
{
|