summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixChan.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-07-03 14:52:55 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-07-03 14:52:55 (GMT)
commit80ba6f385364c497116741643bfc008ec9bfe544 (patch)
tree84118ecaa9257d1f2e99228c0ae52bc98d574b97 /unix/tclUnixChan.c
parent9e3cbe2c2f2edf7bd88649e927c9ac16a4ad0936 (diff)
downloadtcl-80ba6f385364c497116741643bfc008ec9bfe544.zip
tcl-80ba6f385364c497116741643bfc008ec9bfe544.tar.gz
tcl-80ba6f385364c497116741643bfc008ec9bfe544.tar.bz2
Factor out a number of common patterns of use of Tcl_DStringAppend.
Diffstat (limited to 'unix/tclUnixChan.c')
-rw-r--r--unix/tclUnixChan.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/unix/tclUnixChan.c b/unix/tclUnixChan.c
index b05a9f2..3845c44 100644
--- a/unix/tclUnixChan.c
+++ b/unix/tclUnixChan.c
@@ -733,7 +733,7 @@ TtySetOptionProc(
Tcl_UtfToExternalDString(NULL, argv[0], -1, &ds);
iostate.c_cc[VSTART] = *(const cc_t *) Tcl_DStringValue(&ds);
- Tcl_DStringSetLength(&ds, 0);
+ TclDStringClear(&ds);
Tcl_UtfToExternalDString(NULL, argv[1], -1, &ds);
iostate.c_cc[VSTOP] = *(const cc_t *) Tcl_DStringValue(&ds);
@@ -916,7 +916,7 @@ TtyGetOptionProc(
Tcl_ExternalToUtfDString(NULL, (char *) &iostate.c_cc[VSTART], 1, &ds);
Tcl_DStringAppendElement(dsPtr, Tcl_DStringValue(&ds));
- Tcl_DStringSetLength(&ds, 0);
+ TclDStringClear(&ds);
Tcl_ExternalToUtfDString(NULL, (char *) &iostate.c_cc[VSTOP], 1, &ds);
Tcl_DStringAppendElement(dsPtr, Tcl_DStringValue(&ds));