Attachment "errno.patch" to
ticket [468183ffff]
added by
dgp
2002-01-16 04:47:06.
Index: ChangeLog
===================================================================
RCS file: /cvsroot/tcl/tcl/ChangeLog,v
retrieving revision 1.793
diff -u -u -r1.793 ChangeLog
--- ChangeLog 2002/01/15 21:19:06 1.793
+++ ChangeLog 2002/01/15 21:45:48
@@ -1,5 +1,9 @@
2002-01-15 Don Porter <[email protected]>
+ * doc/SetErrno.3 (Tcl_ErrnoMsg): Corrected documentation for
+ Tcl_ErrnoMsg; it takes an integer argument. Thanks to Georgios
+ Petasis. [Bug 468183]
+
* doc/AddErrInfo.3 (Tcl_PosixError):
* doc/Eval.3 (Tcl_EvalFile):
* doc/FileSystem.c (Tcl_FSOpenFileChannel,Tcl_FSOpenFileChannelProc):
Index: doc/SetErrno.3
===================================================================
RCS file: /cvsroot/tcl/tcl/doc/SetErrno.3,v
retrieving revision 1.4
diff -u -u -r1.4 SetErrno.3
--- doc/SetErrno.3 2002/01/15 21:19:06 1.4
+++ doc/SetErrno.3 2002/01/15 21:45:48
@@ -24,10 +24,10 @@
\fBTcl_ErrnoId\fR()
.sp
CONST char *
-\fBTcl_ErrnoMsg\fR()
+\fBTcl_ErrnoMsg\fR(\fIerrorCode\fR)
.sp
.SH ARGUMENTS
-.AS Tcl_Interp *errorCode in
+.AS int errorCode in
.AP int errorCode in
A POSIX error code such as \fBENOENT\fR.
.BE
@@ -50,11 +50,15 @@
Procedures wishing to access \fBerrno\fR should call this procedure
instead of accessing \fBerrno\fR directly.
.PP
-\fBTcl_ErrnoId\fR and \fBTcl_ErrnoMsg\fR return a string
-representation of the current \fBerrno\fR value. \fBTcl_ErrnoId\fR
+\fBTcl_ErrnoId\fR and \fBTcl_ErrnoMsg\fR return string
+representations of \fBerrno\fR values. \fBTcl_ErrnoId\fR
returns a machine-readable textual identifier such as
-"EACCES". \fBTcl_ErrnoMsg\fR returns a human-readable string such as
-"permission denied". The strings returned by these functions are
+"EACCES" that corresponds to the current value of \fBerrno\fR.
+\fBTcl_ErrnoMsg\fR returns a human-readable string such as
+"permission denied" that corresponds to the value of its
+\fIerrorCode\fR argument. The \fIerrorCode\fR argument is
+typically the value returned by \fBTcl_GetErrno\fR.
+The strings returned by these functions are
statically allocated and the caller must not free or modify them.
.SH KEYWORDS