Check-in [5e4e821402]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:merge with trunk
Timelines: family | ancestors | descendants | both | wtf-8-experiment
Files: files | file ages | folders
SHA1: 5e4e821402fd99abedaa5f6049403c3e831b4f00
User & Date: chw 2020-06-25 15:23:45.459
Context
2020-06-26
04:04
merge with trunk check-in: 850f4434c6 user: chw tags: wtf-8-experiment
2020-06-25
15:23
merge with trunk check-in: 5e4e821402 user: chw tags: wtf-8-experiment
15:23
add selected tclx upstream changes check-in: c48d702f1a user: chw tags: trunk
14:33
merge with trunk check-in: 1f030daff9 user: chw tags: wtf-8-experiment
Changes
Unified Diff Ignore Whitespace Patch
Changes to jni/tclx/configure.
13436
13437
13438
13439
13440
13441
13442

13443
13444
13445
13446
13447
13448
13449
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <sys/types.h>
#include <sys/times.h>

main() {
    struct tms cpu;
    times(&cpu);
    sleep(2);
    exit ((times(&cpu) > 0) ? 0 : 1);
}








>







13436
13437
13438
13439
13440
13441
13442
13443
13444
13445
13446
13447
13448
13449
13450
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <sys/types.h>
#include <sys/times.h>
#include <unistd.h>
main() {
    struct tms cpu;
    times(&cpu);
    sleep(2);
    exit ((times(&cpu) > 0) ? 0 : 1);
}

Changes to jni/tclx/configure.in.
207
208
209
210
211
212
213

214
215
216
217
218
219
220
    # time.
    #-------------------------------------------------------------------------
    
    AC_MSG_CHECKING(checking to see what 'times' returns)
    AC_TRY_RUN([
#include <sys/types.h>
#include <sys/times.h>

main() {
    struct tms cpu;
    times(&cpu);
    sleep(2);
    exit ((times(&cpu) > 0) ? 0 : 1);
}
], [AC_MSG_RESULT(elapsed real time)],







>







207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
    # time.
    #-------------------------------------------------------------------------
    
    AC_MSG_CHECKING(checking to see what 'times' returns)
    AC_TRY_RUN([
#include <sys/types.h>
#include <sys/times.h>
#include <unistd.h>
main() {
    struct tms cpu;
    times(&cpu);
    sleep(2);
    exit ((times(&cpu) > 0) ? 0 : 1);
}
], [AC_MSG_RESULT(elapsed real time)],
Changes to jni/tclx/generic/tclExtdInt.h.
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57

/*
 * Assert macro for use in TclX.  Some GCCs libraries are missing a function
 * used by their macro, so we define our own.
 */
#ifdef TCLX_DEBUG
#   define TclX_Assert(expr) ((expr) ? (void)0 : \
                              panic("TclX assertion failure: %s:%d \"%s\"\n",\
                                    __FILE__, __LINE__, "expr"))
#else
#   define TclX_Assert(expr)
#endif

/*
 * Get ranges of integers and longs.







|







43
44
45
46
47
48
49
50
51
52
53
54
55
56
57

/*
 * Assert macro for use in TclX.  Some GCCs libraries are missing a function
 * used by their macro, so we define our own.
 */
#ifdef TCLX_DEBUG
#   define TclX_Assert(expr) ((expr) ? (void)0 : \
                              Tcl_Panic("TclX assertion failure: %s:%d \"%s\"\n",\
                                    __FILE__, __LINE__, "expr"))
#else
#   define TclX_Assert(expr)
#endif

/*
 * Get ranges of integers and longs.
Changes to jni/tclx/generic/tclXdup.c.
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
     * standard files generates an error on some systems.  Skip options
     * that can't be set.
     */
    if (Tcl_SplitList(interp, strValues.string, &optArgc, &optArgv) != TCL_OK) {
        goto errorExit;
    }
    if ((optArgc % 2) != 0) {
        panic("channel didn't return keyword/value pairs");
    }

    for (idx = 0; idx < optArgc; idx += 2) {
        option = optArgv[idx];
        value = optArgv[idx+1];
        if (STREQU (option, "-blocking") && (value [0] != '0')) {
            continue;







|







71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
     * standard files generates an error on some systems.  Skip options
     * that can't be set.
     */
    if (Tcl_SplitList(interp, strValues.string, &optArgc, &optArgv) != TCL_OK) {
        goto errorExit;
    }
    if ((optArgc % 2) != 0) {
        Tcl_Panic("channel didn't return keyword/value pairs");
    }

    for (idx = 0; idx < optArgc; idx += 2) {
        option = optArgv[idx];
        value = optArgv[idx+1];
        if (STREQU (option, "-blocking") && (value [0] != '0')) {
            continue;
Changes to jni/tclx/generic/tclXfcntl.c.
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
        break;
      case ATTR_KEEPALIVE:
        if (TclXOSgetsockopt (interp, channel, SO_KEEPALIVE, &sval) != TCL_OK)
            return TCL_ERROR;
        value = sval;
        break;
      default:
        panic ("bug in fcntl get attrib");
    }

    Tcl_SetIntObj (Tcl_GetObjResult (interp), value != 0);
    return TCL_OK;
}

/*-----------------------------------------------------------------------------







|







202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
        break;
      case ATTR_KEEPALIVE:
        if (TclXOSgetsockopt (interp, channel, SO_KEEPALIVE, &sval) != TCL_OK)
            return TCL_ERROR;
        value = sval;
        break;
      default:
        Tcl_Panic ("bug in fcntl get attrib");
    }

    Tcl_SetIntObj (Tcl_GetObjResult (interp), value != 0);
    return TCL_OK;
}

/*-----------------------------------------------------------------------------
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
      case ATTR_LINEBUF:
        return TclX_SetChannelOption (interp, channel, TCLX_COPT_BUFFERING,
                                      value ? TCLX_BUFFERING_LINE :
                                              TCLX_BUFFERING_FULL);
      case ATTR_KEEPALIVE:
        return TclXOSsetsockopt (interp, channel, SO_KEEPALIVE, value);
      default:
        panic ("buf in fcntl set attrib");
    }
    return TCL_ERROR;  /* Should never be reached */
}

/*-----------------------------------------------------------------------------
 * TclX_FcntlObjCmd --
 *     Implements the fcntl TCL command:







|







257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
      case ATTR_LINEBUF:
        return TclX_SetChannelOption (interp, channel, TCLX_COPT_BUFFERING,
                                      value ? TCLX_BUFFERING_LINE :
                                              TCLX_BUFFERING_FULL);
      case ATTR_KEEPALIVE:
        return TclXOSsetsockopt (interp, channel, SO_KEEPALIVE, value);
      default:
        Tcl_Panic ("buf in fcntl set attrib");
    }
    return TCL_ERROR;  /* Should never be reached */
}

/*-----------------------------------------------------------------------------
 * TclX_FcntlObjCmd --
 *     Implements the fcntl TCL command:
Changes to jni/tclx/generic/tclXhandles.c.
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
TclX_HandleFree (void_pt headerPtr, void_pt entryPtr)
{
    tblHeader_pt   tblHdrPtr = (tblHeader_pt)headerPtr;
    entryHeader_pt entryHdrPtr;

    entryHdrPtr = HEADER_AREA (entryPtr);
    if (entryHdrPtr->freeLink != ALLOCATED_IDX)
        panic ("Tcl_HandleFree: entry not allocated %p\n",
            (char *) entryHdrPtr);

    entryHdrPtr->freeLink = tblHdrPtr->freeHeadIdx;
    tblHdrPtr->freeHeadIdx =
        (((ubyte_pt) entryHdrPtr) - tblHdrPtr->bodyPtr) / tblHdrPtr->entrySize;

}







|







535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
TclX_HandleFree (void_pt headerPtr, void_pt entryPtr)
{
    tblHeader_pt   tblHdrPtr = (tblHeader_pt)headerPtr;
    entryHeader_pt entryHdrPtr;

    entryHdrPtr = HEADER_AREA (entryPtr);
    if (entryHdrPtr->freeLink != ALLOCATED_IDX)
        Tcl_Panic ("Tcl_HandleFree: entry not allocated %p\n",
            (char *) entryHdrPtr);

    entryHdrPtr->freeLink = tblHdrPtr->freeHeadIdx;
    tblHdrPtr->freeHeadIdx =
        (((ubyte_pt) entryHdrPtr) - tblHdrPtr->bodyPtr) / tblHdrPtr->entrySize;

}
Changes to jni/tclx/generic/tclXprofile.c.
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
           ((isProc && (scanPtr->scopeLevel >= scopeLevel)) ||
            ((!isProc) && (scanPtr->scopeLevel > scopeLevel)))) {
        scanPtr = scanPtr->prevScopePtr;
        /*
         * Only global level can be NULL.
         */
        if (scanPtr == NULL)
            panic (PROF_PANIC, 1);
    }
    entryPtr->prevScopePtr = scanPtr;
    infoPtr->scopeChainPtr = entryPtr;
}

/*-----------------------------------------------------------------------------
 * RecordData --







|







212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
           ((isProc && (scanPtr->scopeLevel >= scopeLevel)) ||
            ((!isProc) && (scanPtr->scopeLevel > scopeLevel)))) {
        scanPtr = scanPtr->prevScopePtr;
        /*
         * Only global level can be NULL.
         */
        if (scanPtr == NULL)
            Tcl_Panic (PROF_PANIC, 1);
    }
    entryPtr->prevScopePtr = scanPtr;
    infoPtr->scopeChainPtr = entryPtr;
}

/*-----------------------------------------------------------------------------
 * RecordData --
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
            return TCL_OK;  /* Ignore unknown ops */

        Tcl_ListObjGetElements (NULL, objv[1], &cmdObjc, &cmdObjv);
        if (cmdObjc > 0) {
            cmdName = Tcl_GetStringFromObj (cmdObjv[0], NULL);
            cmd = Tcl_FindCommand (interp, cmdName, NULL, 0);
            if (cmd == NULL)
                panic (PROF_PANIC, 1000);

            fullCmdNameObj = Tcl_NewObj ();
            Tcl_GetCommandFullName (interp, cmd, fullCmdNameObj);
            fullCmdName = Tcl_GetStringFromObj (fullCmdNameObj, NULL);

            /*
             * Determine current proc and var levels.







|







440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
            return TCL_OK;  /* Ignore unknown ops */

        Tcl_ListObjGetElements (NULL, objv[1], &cmdObjc, &cmdObjv);
        if (cmdObjc > 0) {
            cmdName = Tcl_GetStringFromObj (cmdObjv[0], NULL);
            cmd = Tcl_FindCommand (interp, cmdName, NULL, 0);
            if (cmd == NULL)
                Tcl_Panic (PROF_PANIC, 1000);

            fullCmdNameObj = Tcl_NewObj ();
            Tcl_GetCommandFullName (interp, cmd, fullCmdNameObj);
            fullCmdName = Tcl_GetStringFromObj (fullCmdNameObj, NULL);

            /*
             * Determine current proc and var levels.
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
             * initial entries that where pushed on the stack before
             * we started.  Pop those entries.
             */
            if (infoPtr->stackPtr->procLevel > procLevel) {
                UpdateTOSTimes (infoPtr);
                do {
                    if (infoPtr->stackPtr->evalLevel != UNKNOWN_LEVEL)
                        panic (PROF_PANIC, 2);  /* Not an initial entry */
                    if (infoPtr->stackPtr->prevEntryPtr == NULL)
                        break;  /* Keep first entry */
                    PopEntry (infoPtr);
                } while (infoPtr->stackPtr->procLevel > procLevel);
            }

            /*







|







467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
             * initial entries that where pushed on the stack before
             * we started.  Pop those entries.
             */
            if (infoPtr->stackPtr->procLevel > procLevel) {
                UpdateTOSTimes (infoPtr);
                do {
                    if (infoPtr->stackPtr->evalLevel != UNKNOWN_LEVEL)
                        Tcl_Panic (PROF_PANIC, 2);  /* Not an initial entry */
                    if (infoPtr->stackPtr->prevEntryPtr == NULL)
                        break;  /* Keep first entry */
                    PopEntry (infoPtr);
                } while (infoPtr->stackPtr->procLevel > procLevel);
            }

            /*
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
            return TCL_OK;  /* Ignore unknown ops */

        Tcl_ListObjGetElements (NULL, objv[1], &cmdObjc, &cmdObjv);
        if (cmdObjc > 0) {
            cmdName = Tcl_GetStringFromObj (cmdObjv[0], NULL);
            cmd = Tcl_FindCommand (interp, cmdName, NULL, 0);
            if (cmd == NULL)
                panic (PROF_PANIC, 1001);

            fullCmdNameObj = Tcl_NewObj ();
            Tcl_GetCommandFullName (interp, cmd, fullCmdNameObj);
            fullCmdName = Tcl_GetStringFromObj (fullCmdNameObj, NULL);

            /*
             * Pop the entry, recording the information.







|







511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
            return TCL_OK;  /* Ignore unknown ops */

        Tcl_ListObjGetElements (NULL, objv[1], &cmdObjc, &cmdObjv);
        if (cmdObjc > 0) {
            cmdName = Tcl_GetStringFromObj (cmdObjv[0], NULL);
            cmd = Tcl_FindCommand (interp, cmdName, NULL, 0);
            if (cmd == NULL)
                Tcl_Panic (PROF_PANIC, 1001);

            fullCmdNameObj = Tcl_NewObj ();
            Tcl_GetCommandFullName (interp, cmd, fullCmdNameObj);
            fullCmdName = Tcl_GetStringFromObj (fullCmdNameObj, NULL);

            /*
             * Pop the entry, recording the information.
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
    while ((scanPtr != NULL) && (scanPtr->scopeLevel >= scopeLevel) &&
           (scanPtr->procLevel > 0)) {
        scanPtr = scanPtr->prevScopePtr;
        /*
         * Only global level can be NULL.
         */
        if (scanPtr == NULL)
            panic (PROF_PANIC, 6);
    }
    infoPtr->scopeChainPtr = scanPtr;

    /*
     * Get the time we started.
     */
    TclXOSElapsedTime (&infoPtr->realTime, &infoPtr->cpuTime);







|







668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
    while ((scanPtr != NULL) && (scanPtr->scopeLevel >= scopeLevel) &&
           (scanPtr->procLevel > 0)) {
        scanPtr = scanPtr->prevScopePtr;
        /*
         * Only global level can be NULL.
         */
        if (scanPtr == NULL)
            Tcl_Panic (PROF_PANIC, 6);
    }
    infoPtr->scopeChainPtr = scanPtr;

    /*
     * Get the time we started.
     */
    TclXOSElapsedTime (&infoPtr->realTime, &infoPtr->cpuTime);
Changes to jni/tclx/generic/tclXsignal.c.
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
     * Not done for SIGCHLD, as we would continue to the signal until the
     * wait is done.  This is fixed by Posix signals and is not necessary under
     * BSD, but it done this way for consistency.
     */
#ifdef SIGCHLD
    if (signalNum != SIGCHLD) {
        if (SetSignalState (signalNum, SignalTrap, FALSE) == TCL_ERROR)
            panic ("SignalTrap bug");
    }
#else
    if (SetSignalState (signalNum, SignalTrap, FALSE) == TCL_ERROR)
        panic ("SignalTrap bug");
#endif /* SIGCHLD */
#endif /* NO_SIGACTION */
}

/*-----------------------------------------------------------------------------
 * FormatTrapCode --
 *     Format the signal name into the signal trap command.  Replacing %S with







|



|







632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
     * Not done for SIGCHLD, as we would continue to the signal until the
     * wait is done.  This is fixed by Posix signals and is not necessary under
     * BSD, but it done this way for consistency.
     */
#ifdef SIGCHLD
    if (signalNum != SIGCHLD) {
        if (SetSignalState (signalNum, SignalTrap, FALSE) == TCL_ERROR)
            Tcl_Panic ("SignalTrap bug");
    }
#else
    if (SetSignalState (signalNum, SignalTrap, FALSE) == TCL_ERROR)
        Tcl_Panic ("SignalTrap bug");
#endif /* SIGCHLD */
#endif /* NO_SIGACTION */
}

/*-----------------------------------------------------------------------------
 * FormatTrapCode --
 *     Format the signal name into the signal trap command.  Replacing %S with
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
    int idx;

    for (idx = 0; idx < tsdPtr->numInterps; idx++) {
        if (tsdPtr->interpTable [idx] == interp)
            break;
    }
    if (idx == tsdPtr->numInterps)
        panic ("signal interp lost");

    tsdPtr->interpTable [idx] = tsdPtr->interpTable [--tsdPtr->numInterps];

    /*
     * If there are no more interpreters, clean everything up.
     */
    if (tsdPtr->numInterps == 0) {







|







1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
    int idx;

    for (idx = 0; idx < tsdPtr->numInterps; idx++) {
        if (tsdPtr->interpTable [idx] == interp)
            break;
    }
    if (idx == tsdPtr->numInterps)
        Tcl_Panic ("signal interp lost");

    tsdPtr->interpTable [idx] = tsdPtr->interpTable [--tsdPtr->numInterps];

    /*
     * If there are no more interpreters, clean everything up.
     */
    if (tsdPtr->numInterps == 0) {
Changes to jni/tclx/generic/tclXutil.c.
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
    } else if (STREQU (strValue, "cr")) {
        return TCLX_TRANSLATE_CR;
    } else if (STREQU (strValue, "crlf")) {
        return TCLX_TRANSLATE_CRLF;
    } else if (STREQU (strValue, "platform")) {
        return TCLX_TRANSLATE_PLATFORM;
    }
    panic ("ParseTranslationOption bug");
    return TCL_ERROR;  /* Not reached */
}

/*-----------------------------------------------------------------------------
 * FormatTranslationOption --
 *
 *   Format the string that represents the translation value for one channel







|







472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
    } else if (STREQU (strValue, "cr")) {
        return TCLX_TRANSLATE_CR;
    } else if (STREQU (strValue, "crlf")) {
        return TCLX_TRANSLATE_CRLF;
    } else if (STREQU (strValue, "platform")) {
        return TCLX_TRANSLATE_PLATFORM;
    }
    Tcl_Panic ("ParseTranslationOption bug");
    return TCL_ERROR;  /* Not reached */
}

/*-----------------------------------------------------------------------------
 * FormatTranslationOption --
 *
 *   Format the string that represents the translation value for one channel
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
      case TCLX_TRANSLATE_CR:
        return "cr";
      case TCLX_TRANSLATE_CRLF:
        return "crlf";
      case TCLX_TRANSLATE_PLATFORM:
        return "platform";
      default:
        panic ("FormatTranslationOption bug");
    }
    return NULL;  /* Not reached */
}


/*-----------------------------------------------------------------------------
 * TclX_GetChannelOption --







|







503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
      case TCLX_TRANSLATE_CR:
        return "cr";
      case TCLX_TRANSLATE_CRLF:
        return "crlf";
      case TCLX_TRANSLATE_PLATFORM:
        return "platform";
      default:
        Tcl_Panic ("FormatTranslationOption bug");
    }
    return NULL;  /* Not reached */
}


/*-----------------------------------------------------------------------------
 * TclX_GetChannelOption --
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
      }
    }
    Tcl_DStringFree (&strValue);
    *valuePtr = value;
    return TCL_OK;

  fatalError:
    panic ("TclX_GetChannelOption bug");  /* FIX: return error. */
    return 0;  /* Not reached */
}

/*-----------------------------------------------------------------------------
 * TclX_SetChannelOption --
 *
 *   C-friendly front end to Tcl_SetChannelOption.







|







616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
      }
    }
    Tcl_DStringFree (&strValue);
    *valuePtr = value;
    return TCL_OK;

  fatalError:
    Tcl_Panic ("TclX_GetChannelOption bug");  /* FIX: return error. */
    return 0;  /* Not reached */
}

/*-----------------------------------------------------------------------------
 * TclX_SetChannelOption --
 *
 *   C-friendly front end to Tcl_SetChannelOption.
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
      default:
        goto fatalError;
    }

    return Tcl_SetChannelOption (interp, channel, strOption, strValue);

  fatalError:
    panic ("TclX_SetChannelOption bug");
    return TCL_ERROR;  /* Not reached */
}

/*-----------------------------------------------------------------------------
 * TclX_JoinPath --
 *
 *   Interface to Tcl_Join path to join only two files.







|







711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
      default:
        goto fatalError;
    }

    return Tcl_SetChannelOption (interp, channel, strOption, strValue);

  fatalError:
    Tcl_Panic ("TclX_SetChannelOption bug");
    return TCL_ERROR;  /* Not reached */
}

/*-----------------------------------------------------------------------------
 * TclX_JoinPath --
 *
 *   Interface to Tcl_Join path to join only two files.
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
    if ((Tcl_ListObjGetElements (NULL, saveObjPtr, &saveObjc,
                                 &saveObjv) != TCL_OK) ||
        (saveObjc != 4) ||
        (Tcl_GetLongFromObj (NULL, saveObjv[3], &flags) != TCL_OK)) {
        /*
         * This should never happen
         */
        panic ("invalid TclX result save object");
    }

    Tcl_SetVar2Ex(interp, ERRORCODE, NULL, saveObjv[2], TCL_GLOBAL_ONLY);
    Tcl_SetVar2Ex(interp, ERRORINFO, NULL, saveObjv[1], TCL_GLOBAL_ONLY);

    Tcl_ResetResult(interp);
    Tcl_AppendObjToErrorInfo(interp, saveObjv[1]);







|







920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
    if ((Tcl_ListObjGetElements (NULL, saveObjPtr, &saveObjc,
                                 &saveObjv) != TCL_OK) ||
        (saveObjc != 4) ||
        (Tcl_GetLongFromObj (NULL, saveObjv[3], &flags) != TCL_OK)) {
        /*
         * This should never happen
         */
        Tcl_Panic ("invalid TclX result save object");
    }

    Tcl_SetVar2Ex(interp, ERRORCODE, NULL, saveObjv[2], TCL_GLOBAL_ONLY);
    Tcl_SetVar2Ex(interp, ERRORINFO, NULL, saveObjv[1], TCL_GLOBAL_ONLY);

    Tcl_ResetResult(interp);
    Tcl_AppendObjToErrorInfo(interp, saveObjv[1]);
Changes to jni/tclx/tclconfig/tcl.m4.
2568
2569
2570
2571
2572
2573
2574

2575
2576
2577
2578
2579
2580
2581
#--------------------------------------------------------------------

AC_DEFUN([TEA_BUGGY_STRTOD], [
    AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0)
    if test "$tcl_strtod" = 1; then
	AC_CACHE_CHECK([for Solaris2.4/Tru64 strtod bugs], tcl_cv_strtod_buggy,[
	    AC_TRY_RUN([

		extern double strtod();
		int main() {
		    char *infString="Inf", *nanString="NaN", *spaceString=" ";
		    char *term;
		    double value;
		    value = strtod(infString, &term);
		    if ((term != infString) && (term[-1] == 0)) {







>







2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
#--------------------------------------------------------------------

AC_DEFUN([TEA_BUGGY_STRTOD], [
    AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0)
    if test "$tcl_strtod" = 1; then
	AC_CACHE_CHECK([for Solaris2.4/Tru64 strtod bugs], tcl_cv_strtod_buggy,[
	    AC_TRY_RUN([
		#include <stdlib.h>
		extern double strtod();
		int main() {
		    char *infString="Inf", *nanString="NaN", *spaceString=" ";
		    char *term;
		    double value;
		    value = strtod(infString, &term);
		    if ((term != infString) && (term[-1] == 0)) {
Changes to jni/tclx/unix/tclXunixPort.h.
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include <grp.h>
#include <assert.h>

#ifndef __xlC__ /* AIX xlc */
extern int h_errno;
#endif

#ifdef __APPLE__
# undef  panic
# define panic Tcl_Panic
#endif

/*
 * Included the tcl file tclUnixPort.h after other system files, as it checks
 * if certain things are defined.
 */
#include "tclUnixPort.h"

/*







<
<
<
<
<







33
34
35
36
37
38
39





40
41
42
43
44
45
46
#include <grp.h>
#include <assert.h>

#ifndef __xlC__ /* AIX xlc */
extern int h_errno;
#endif






/*
 * Included the tcl file tclUnixPort.h after other system files, as it checks
 * if certain things are defined.
 */
#include "tclUnixPort.h"

/*
Changes to jni/tclx/win/tclXwinOS.c.
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
      case TCLX_WIN_SOCKET:
        TclX_AppendObjResult (interp, "can't lock a socket under windows",
                              (char *) NULL);
        return INVALID_HANDLE_VALUE;
      case TCLX_WIN_CONSOLE:
        break;  /* FIX: Is this legal?? */
      default:
        panic ("unknown win channel type %d\n", type);
    }

    /*
     * Calculate actual offset of the start.
     */
    switch (lockInfoPtr->whence) {
      case 0:  /* start */







|







1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
      case TCLX_WIN_SOCKET:
        TclX_AppendObjResult (interp, "can't lock a socket under windows",
                              (char *) NULL);
        return INVALID_HANDLE_VALUE;
      case TCLX_WIN_CONSOLE:
        break;  /* FIX: Is this legal?? */
      default:
        Tcl_Panic ("unknown win channel type %d\n", type);
    }

    /*
     * Calculate actual offset of the start.
     */
    switch (lockInfoPtr->whence) {
      case 0:  /* start */