MCPcopy Create free account
hub / github.com/OpenSees/OpenSees / Tcl_SetStartupScript

Function Tcl_SetStartupScript

SRC/tcl/tclMain85.cpp:147–172  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

145 *----------------------------------------------------------------------
146 */
147
148void
149Tcl_SetStartupScript(
150 Tcl_Obj *path, /* Filesystem path of startup script file */
151 CONST char *encoding) /* Encoding of the data in that file */
152{
153 Tcl_Obj *newEncoding = NULL;
154 if (encoding != NULL) {
155 newEncoding = Tcl_NewStringObj(encoding, -1);
156 }
157
158 if (tclStartupScriptPath != NULL) {
159 Tcl_DecrRefCount(tclStartupScriptPath);
160 }
161 tclStartupScriptPath = path;
162 if (tclStartupScriptPath != NULL) {
163 Tcl_IncrRefCount(tclStartupScriptPath);
164 }
165
166 if (tclStartupScriptEncoding != NULL) {
167 Tcl_DecrRefCount(tclStartupScriptEncoding);
168 }
169 tclStartupScriptEncoding = newEncoding;
170 if (tclStartupScriptEncoding != NULL) {
171 Tcl_IncrRefCount(tclStartupScriptEncoding);
172 }
173}
174
175

Callers 3

TclSetStartupScriptPathFunction · 0.85
tclMain85.cppFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected