summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixFile.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-08-05 12:09:12 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-08-05 12:09:12 (GMT)
commit13147008eb79f31b7f144a848233b4a28591b2d9 (patch)
treeabf0fe6884e78232b9fa8bb36a11d16458869c8a /unix/tclUnixFile.c
parentd8bae8d8c160bda642defb70d49448aadd1b6068 (diff)
downloadtcl-13147008eb79f31b7f144a848233b4a28591b2d9.zip
tcl-13147008eb79f31b7f144a848233b4a28591b2d9.tar.gz
tcl-13147008eb79f31b7f144a848233b4a28591b2d9.tar.bz2
Final part of result generation conversion (modulo any minor blunders)
Diffstat (limited to 'unix/tclUnixFile.c')
-rw-r--r--unix/tclUnixFile.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/unix/tclUnixFile.c b/unix/tclUnixFile.c
index c213050..01fc6fe 100644
--- a/unix/tclUnixFile.c
+++ b/unix/tclUnixFile.c
@@ -310,10 +310,9 @@ TclpMatchInDirectory(
if (d == NULL) {
Tcl_DStringFree(&ds);
if (interp != NULL) {
- Tcl_ResetResult(interp);
- Tcl_AppendResult(interp, "couldn't read directory \"",
- Tcl_DStringValue(&dsOrig), "\": ",
- Tcl_PosixError(interp), NULL);
+ Tcl_SetObjResult(interp, Tcl_ObjPrintf(
+ "couldn't read directory \"%s\": %s",
+ Tcl_DStringValue(&dsOrig), Tcl_PosixError(interp)));
}
Tcl_DStringFree(&dsOrig);
Tcl_DecrRefCount(fileNamePtr);
@@ -771,9 +770,9 @@ TclpGetCwd(
#endif
{
if (interp != NULL) {
- Tcl_AppendResult(interp,
- "error getting working directory name: ",
- Tcl_PosixError(interp), NULL);
+ Tcl_SetObjResult(interp, Tcl_ObjPrintf(
+ "error getting working directory name: %s",
+ Tcl_PosixError(interp)));
}
return NULL;
}