Fossil SCM
More style cleanup.
Commit
e4e2f9f7b89e1c72b90943d923ff270729c51904
Parent
ea3d77c4aaf973e…
1 file changed
+11
-11
+11
-11
| --- src/th_tcl.c | ||
| +++ src/th_tcl.c | ||
| @@ -109,20 +109,20 @@ | ||
| 109 | 109 | # define TCL_MINOR_OFFSET (8) |
| 110 | 110 | # endif |
| 111 | 111 | # endif /* defined(__CYGWIN__) */ |
| 112 | 112 | # endif /* defined(_WIN32) */ |
| 113 | 113 | # ifndef TCL_FINDEXECUTABLE_NAME |
| 114 | -# define TCL_FINDEXECUTABLE_NAME "_Tcl_FindExecutable" | |
| 114 | +# define TCL_FINDEXECUTABLE_NAME "_Tcl_FindExecutable\0" | |
| 115 | 115 | # endif |
| 116 | 116 | # ifndef TCL_CREATEINTERP_NAME |
| 117 | -# define TCL_CREATEINTERP_NAME "_Tcl_CreateInterp" | |
| 117 | +# define TCL_CREATEINTERP_NAME "_Tcl_CreateInterp\0" | |
| 118 | 118 | # endif |
| 119 | 119 | # ifndef TCL_DELETEINTERP_NAME |
| 120 | -# define TCL_DELETEINTERP_NAME "_Tcl_DeleteInterp" | |
| 120 | +# define TCL_DELETEINTERP_NAME "_Tcl_DeleteInterp\0" | |
| 121 | 121 | # endif |
| 122 | 122 | # ifndef TCL_FINALIZE_NAME |
| 123 | -# define TCL_FINALIZE_NAME "_Tcl_Finalize" | |
| 123 | +# define TCL_FINALIZE_NAME "_Tcl_Finalize\0" | |
| 124 | 124 | # endif |
| 125 | 125 | #endif /* defined(USE_TCL_STUBS) */ |
| 126 | 126 | |
| 127 | 127 | /* |
| 128 | 128 | ** The function types for Tcl_FindExecutable and Tcl_CreateInterp are needed |
| @@ -311,17 +311,17 @@ | ||
| 311 | 311 | int rc |
| 312 | 312 | ){ |
| 313 | 313 | struct TclContext *tclContext = (struct TclContext *)ctx; |
| 314 | 314 | tcl_NotifyProc *xNotifyProc; |
| 315 | 315 | |
| 316 | - if ( !tclContext ){ | |
| 316 | + if( !tclContext ){ | |
| 317 | 317 | Th_ErrorMessage(interp, |
| 318 | 318 | "invalid Tcl context", (const char *)"", 0); |
| 319 | 319 | return TH_ERROR; |
| 320 | 320 | } |
| 321 | 321 | xNotifyProc = bIsPost ? tclContext->xPostEval : tclContext->xPreEval; |
| 322 | - if ( xNotifyProc ){ | |
| 322 | + if( xNotifyProc ){ | |
| 323 | 323 | rc = xNotifyProc(bIsPost ? |
| 324 | 324 | tclContext->pPostContext : tclContext->pPreContext, |
| 325 | 325 | interp, ctx, argc, argv, argl, rc); |
| 326 | 326 | } |
| 327 | 327 | return rc; |
| @@ -783,16 +783,16 @@ | ||
| 783 | 783 | char **argv; |
| 784 | 784 | char *argv0 = 0; |
| 785 | 785 | Tcl_Interp *tclInterp; |
| 786 | 786 | char *setup; |
| 787 | 787 | |
| 788 | - if ( !tclContext ){ | |
| 788 | + if( !tclContext ){ | |
| 789 | 789 | Th_ErrorMessage(interp, |
| 790 | 790 | "invalid Tcl context", (const char *)"", 0); |
| 791 | 791 | return TH_ERROR; |
| 792 | 792 | } |
| 793 | - if ( tclContext->interp ){ | |
| 793 | + if( tclContext->interp ){ | |
| 794 | 794 | return TH_OK; |
| 795 | 795 | } |
| 796 | 796 | if( loadTcl(interp, &tclContext->library, &tclContext->xFindExecutable, |
| 797 | 797 | &tclContext->xCreateInterp, &tclContext->xDeleteInterp, |
| 798 | 798 | &tclContext->xFinalize)!=TH_OK ){ |
| @@ -882,11 +882,11 @@ | ||
| 882 | 882 | tcl_FinalizeProc *xFinalize; |
| 883 | 883 | #if defined(USE_TCL_STUBS) |
| 884 | 884 | void *library; |
| 885 | 885 | #endif /* defined(USE_TCL_STUBS) */ |
| 886 | 886 | |
| 887 | - if ( !tclContext ){ | |
| 887 | + if( !tclContext ){ | |
| 888 | 888 | Th_ErrorMessage(interp, |
| 889 | 889 | "invalid Tcl context", (const char *)"", 0); |
| 890 | 890 | return TH_ERROR; |
| 891 | 891 | } |
| 892 | 892 | /* |
| @@ -897,11 +897,11 @@ | ||
| 897 | 897 | xFinalize = tclContext->xFinalize; |
| 898 | 898 | /* |
| 899 | 899 | ** If the Tcl interpreter has been created, formally delete it now. |
| 900 | 900 | */ |
| 901 | 901 | tclInterp = tclContext->interp; |
| 902 | - if ( tclInterp ){ | |
| 902 | + if( tclInterp ){ | |
| 903 | 903 | Tcl_DeleteInterp(tclInterp); |
| 904 | 904 | tclContext->interp = tclInterp = 0; |
| 905 | 905 | } |
| 906 | 906 | /* |
| 907 | 907 | ** If the Tcl library is not finalized prior to unloading it, a deadlock |
| @@ -939,15 +939,15 @@ | ||
| 939 | 939 | int i; |
| 940 | 940 | |
| 941 | 941 | /* Add the Tcl integration commands to TH1. */ |
| 942 | 942 | for(i=0; i<(sizeof(aCommand)/sizeof(aCommand[0])); i++){ |
| 943 | 943 | void *ctx; |
| 944 | - if ( !aCommand[i].zName || !aCommand[i].xProc ) continue; | |
| 944 | + if( !aCommand[i].zName || !aCommand[i].xProc ) continue; | |
| 945 | 945 | ctx = aCommand[i].pContext; |
| 946 | 946 | /* Use Tcl interpreter for context? */ |
| 947 | 947 | if( !ctx ) ctx = pContext; |
| 948 | 948 | Th_CreateCommand(interp, aCommand[i].zName, aCommand[i].xProc, ctx, 0); |
| 949 | 949 | } |
| 950 | 950 | return TH_OK; |
| 951 | 951 | } |
| 952 | 952 | |
| 953 | 953 | #endif /* FOSSIL_ENABLE_TCL */ |
| 954 | 954 |
| --- src/th_tcl.c | |
| +++ src/th_tcl.c | |
| @@ -109,20 +109,20 @@ | |
| 109 | # define TCL_MINOR_OFFSET (8) |
| 110 | # endif |
| 111 | # endif /* defined(__CYGWIN__) */ |
| 112 | # endif /* defined(_WIN32) */ |
| 113 | # ifndef TCL_FINDEXECUTABLE_NAME |
| 114 | # define TCL_FINDEXECUTABLE_NAME "_Tcl_FindExecutable" |
| 115 | # endif |
| 116 | # ifndef TCL_CREATEINTERP_NAME |
| 117 | # define TCL_CREATEINTERP_NAME "_Tcl_CreateInterp" |
| 118 | # endif |
| 119 | # ifndef TCL_DELETEINTERP_NAME |
| 120 | # define TCL_DELETEINTERP_NAME "_Tcl_DeleteInterp" |
| 121 | # endif |
| 122 | # ifndef TCL_FINALIZE_NAME |
| 123 | # define TCL_FINALIZE_NAME "_Tcl_Finalize" |
| 124 | # endif |
| 125 | #endif /* defined(USE_TCL_STUBS) */ |
| 126 | |
| 127 | /* |
| 128 | ** The function types for Tcl_FindExecutable and Tcl_CreateInterp are needed |
| @@ -311,17 +311,17 @@ | |
| 311 | int rc |
| 312 | ){ |
| 313 | struct TclContext *tclContext = (struct TclContext *)ctx; |
| 314 | tcl_NotifyProc *xNotifyProc; |
| 315 | |
| 316 | if ( !tclContext ){ |
| 317 | Th_ErrorMessage(interp, |
| 318 | "invalid Tcl context", (const char *)"", 0); |
| 319 | return TH_ERROR; |
| 320 | } |
| 321 | xNotifyProc = bIsPost ? tclContext->xPostEval : tclContext->xPreEval; |
| 322 | if ( xNotifyProc ){ |
| 323 | rc = xNotifyProc(bIsPost ? |
| 324 | tclContext->pPostContext : tclContext->pPreContext, |
| 325 | interp, ctx, argc, argv, argl, rc); |
| 326 | } |
| 327 | return rc; |
| @@ -783,16 +783,16 @@ | |
| 783 | char **argv; |
| 784 | char *argv0 = 0; |
| 785 | Tcl_Interp *tclInterp; |
| 786 | char *setup; |
| 787 | |
| 788 | if ( !tclContext ){ |
| 789 | Th_ErrorMessage(interp, |
| 790 | "invalid Tcl context", (const char *)"", 0); |
| 791 | return TH_ERROR; |
| 792 | } |
| 793 | if ( tclContext->interp ){ |
| 794 | return TH_OK; |
| 795 | } |
| 796 | if( loadTcl(interp, &tclContext->library, &tclContext->xFindExecutable, |
| 797 | &tclContext->xCreateInterp, &tclContext->xDeleteInterp, |
| 798 | &tclContext->xFinalize)!=TH_OK ){ |
| @@ -882,11 +882,11 @@ | |
| 882 | tcl_FinalizeProc *xFinalize; |
| 883 | #if defined(USE_TCL_STUBS) |
| 884 | void *library; |
| 885 | #endif /* defined(USE_TCL_STUBS) */ |
| 886 | |
| 887 | if ( !tclContext ){ |
| 888 | Th_ErrorMessage(interp, |
| 889 | "invalid Tcl context", (const char *)"", 0); |
| 890 | return TH_ERROR; |
| 891 | } |
| 892 | /* |
| @@ -897,11 +897,11 @@ | |
| 897 | xFinalize = tclContext->xFinalize; |
| 898 | /* |
| 899 | ** If the Tcl interpreter has been created, formally delete it now. |
| 900 | */ |
| 901 | tclInterp = tclContext->interp; |
| 902 | if ( tclInterp ){ |
| 903 | Tcl_DeleteInterp(tclInterp); |
| 904 | tclContext->interp = tclInterp = 0; |
| 905 | } |
| 906 | /* |
| 907 | ** If the Tcl library is not finalized prior to unloading it, a deadlock |
| @@ -939,15 +939,15 @@ | |
| 939 | int i; |
| 940 | |
| 941 | /* Add the Tcl integration commands to TH1. */ |
| 942 | for(i=0; i<(sizeof(aCommand)/sizeof(aCommand[0])); i++){ |
| 943 | void *ctx; |
| 944 | if ( !aCommand[i].zName || !aCommand[i].xProc ) continue; |
| 945 | ctx = aCommand[i].pContext; |
| 946 | /* Use Tcl interpreter for context? */ |
| 947 | if( !ctx ) ctx = pContext; |
| 948 | Th_CreateCommand(interp, aCommand[i].zName, aCommand[i].xProc, ctx, 0); |
| 949 | } |
| 950 | return TH_OK; |
| 951 | } |
| 952 | |
| 953 | #endif /* FOSSIL_ENABLE_TCL */ |
| 954 |
| --- src/th_tcl.c | |
| +++ src/th_tcl.c | |
| @@ -109,20 +109,20 @@ | |
| 109 | # define TCL_MINOR_OFFSET (8) |
| 110 | # endif |
| 111 | # endif /* defined(__CYGWIN__) */ |
| 112 | # endif /* defined(_WIN32) */ |
| 113 | # ifndef TCL_FINDEXECUTABLE_NAME |
| 114 | # define TCL_FINDEXECUTABLE_NAME "_Tcl_FindExecutable\0" |
| 115 | # endif |
| 116 | # ifndef TCL_CREATEINTERP_NAME |
| 117 | # define TCL_CREATEINTERP_NAME "_Tcl_CreateInterp\0" |
| 118 | # endif |
| 119 | # ifndef TCL_DELETEINTERP_NAME |
| 120 | # define TCL_DELETEINTERP_NAME "_Tcl_DeleteInterp\0" |
| 121 | # endif |
| 122 | # ifndef TCL_FINALIZE_NAME |
| 123 | # define TCL_FINALIZE_NAME "_Tcl_Finalize\0" |
| 124 | # endif |
| 125 | #endif /* defined(USE_TCL_STUBS) */ |
| 126 | |
| 127 | /* |
| 128 | ** The function types for Tcl_FindExecutable and Tcl_CreateInterp are needed |
| @@ -311,17 +311,17 @@ | |
| 311 | int rc |
| 312 | ){ |
| 313 | struct TclContext *tclContext = (struct TclContext *)ctx; |
| 314 | tcl_NotifyProc *xNotifyProc; |
| 315 | |
| 316 | if( !tclContext ){ |
| 317 | Th_ErrorMessage(interp, |
| 318 | "invalid Tcl context", (const char *)"", 0); |
| 319 | return TH_ERROR; |
| 320 | } |
| 321 | xNotifyProc = bIsPost ? tclContext->xPostEval : tclContext->xPreEval; |
| 322 | if( xNotifyProc ){ |
| 323 | rc = xNotifyProc(bIsPost ? |
| 324 | tclContext->pPostContext : tclContext->pPreContext, |
| 325 | interp, ctx, argc, argv, argl, rc); |
| 326 | } |
| 327 | return rc; |
| @@ -783,16 +783,16 @@ | |
| 783 | char **argv; |
| 784 | char *argv0 = 0; |
| 785 | Tcl_Interp *tclInterp; |
| 786 | char *setup; |
| 787 | |
| 788 | if( !tclContext ){ |
| 789 | Th_ErrorMessage(interp, |
| 790 | "invalid Tcl context", (const char *)"", 0); |
| 791 | return TH_ERROR; |
| 792 | } |
| 793 | if( tclContext->interp ){ |
| 794 | return TH_OK; |
| 795 | } |
| 796 | if( loadTcl(interp, &tclContext->library, &tclContext->xFindExecutable, |
| 797 | &tclContext->xCreateInterp, &tclContext->xDeleteInterp, |
| 798 | &tclContext->xFinalize)!=TH_OK ){ |
| @@ -882,11 +882,11 @@ | |
| 882 | tcl_FinalizeProc *xFinalize; |
| 883 | #if defined(USE_TCL_STUBS) |
| 884 | void *library; |
| 885 | #endif /* defined(USE_TCL_STUBS) */ |
| 886 | |
| 887 | if( !tclContext ){ |
| 888 | Th_ErrorMessage(interp, |
| 889 | "invalid Tcl context", (const char *)"", 0); |
| 890 | return TH_ERROR; |
| 891 | } |
| 892 | /* |
| @@ -897,11 +897,11 @@ | |
| 897 | xFinalize = tclContext->xFinalize; |
| 898 | /* |
| 899 | ** If the Tcl interpreter has been created, formally delete it now. |
| 900 | */ |
| 901 | tclInterp = tclContext->interp; |
| 902 | if( tclInterp ){ |
| 903 | Tcl_DeleteInterp(tclInterp); |
| 904 | tclContext->interp = tclInterp = 0; |
| 905 | } |
| 906 | /* |
| 907 | ** If the Tcl library is not finalized prior to unloading it, a deadlock |
| @@ -939,15 +939,15 @@ | |
| 939 | int i; |
| 940 | |
| 941 | /* Add the Tcl integration commands to TH1. */ |
| 942 | for(i=0; i<(sizeof(aCommand)/sizeof(aCommand[0])); i++){ |
| 943 | void *ctx; |
| 944 | if( !aCommand[i].zName || !aCommand[i].xProc ) continue; |
| 945 | ctx = aCommand[i].pContext; |
| 946 | /* Use Tcl interpreter for context? */ |
| 947 | if( !ctx ) ctx = pContext; |
| 948 | Th_CreateCommand(interp, aCommand[i].zName, aCommand[i].xProc, ctx, 0); |
| 949 | } |
| 950 | return TH_OK; |
| 951 | } |
| 952 | |
| 953 | #endif /* FOSSIL_ENABLE_TCL */ |
| 954 |