changeset 5109:1e36493572a0

[project @ 2005-01-18 20:17:53 by jwe]
author jwe
date Tue, 18 Jan 2005 20:17:53 +0000
parents 10004c9625c3
children ea96466f98ea
files src/ChangeLog src/file-io.cc
diffstat 2 files changed, 8 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Tue Jan 18 20:05:10 2005 +0000
+++ b/src/ChangeLog	Tue Jan 18 20:17:53 2005 +0000
@@ -1,3 +1,8 @@
+2005-01-18  John W. Eaton  <jwe@octave.org>
+
+	* file-io.cc (Fmkstemp): Fix doc string.  Error message belongs in
+	third output value.  From Mats Jansson <mats.e.jansson@home.se>.
+
 2005-01-12  John W. Eaton  <jwe@octave.org>
 
 	* DLD-FUNCTIONS/find.cc (Ffind): Make it work for character strings.
--- a/src/file-io.cc	Tue Jan 18 20:05:10 2005 +0000
+++ b/src/file-io.cc	Tue Jan 18 20:17:53 2005 +0000
@@ -1797,7 +1797,7 @@
 
 DEFUN (mkstemp, args, ,
   "-*- texinfo -*-\n\
-@deftypefn {Built-in Function} {[@var{fid}, @var{name}, @var{msg}] =} tmpfile (@var{template}, @var{delete})\n\
+@deftypefn {Built-in Function} {[@var{fid}, @var{name}, @var{msg}] =} mkstemp (@var{template}, @var{delete})\n\
 Return the file ID corresponding to a new temporary file with a unique\n\
 name created from @var{template}.  The last six characters of @var{template}\n\
 must be @code{XXXXXX} and these are replaced with a string that makes the\n\
@@ -1841,7 +1841,7 @@
 	  if (fd < 0)
 	    {
 	      using namespace std;
-	      retval(1) = ::strerror (errno);
+	      retval(2) = ::strerror (errno);
 	      retval(0) = fd;
 	    }
 	  else
@@ -1872,7 +1872,7 @@
 	      else
 		{
 		  using namespace std;
-		  retval(1) = ::strerror (errno);
+		  retval(2) = ::strerror (errno);
 		  retval(0) = -1;
 		}
 	    }