diff src/c-file-ptr-stream.h @ 3951:e6f67a1ed814

[project @ 2002-05-23 03:41:25 by jwe]
author jwe
date Thu, 23 May 2002 03:41:25 +0000
parents 818f5aec1db5
children 7690958e7726
line wrap: on
line diff
--- a/src/c-file-ptr-stream.h	Thu May 23 03:00:00 2002 +0000
+++ b/src/c-file-ptr-stream.h	Thu May 23 03:41:25 2002 +0000
@@ -68,7 +68,7 @@
 
   FILE* stdiofile (void) const { return f; }
 
-  c_file_ptr_buf (FILE *f_arg, close_fcn cf_arg = ::fclose)
+  c_file_ptr_buf (FILE *f_arg, close_fcn cf_arg = fclose)
     : 
 #if defined __GNUC__ && __GNUC__ >= 3
     OCTAVE_STD_FILEBUF (f_arg, std::ios::in | std::ios::out),
@@ -107,6 +107,8 @@
 
   int file_number () const { return fd; }
 
+  static int fclose (FILE *f) { return ::fclose (f); }
+
 protected:
 
   FILE *f;
@@ -125,7 +127,8 @@
 {
 public:
 
-  i_c_file_ptr_stream (FILE* f, c_file_ptr_buf::close_fcn cf = ::fclose)
+  i_c_file_ptr_stream (FILE* f,
+		       c_file_ptr_buf::close_fcn cf = c_file_ptr_buf::fclose)
     : std::istream (0), buf (new c_file_ptr_buf (f, cf)) { init (buf); }
 
   ~i_c_file_ptr_stream (void) { delete buf; buf = 0; }
@@ -144,7 +147,8 @@
 {
 public:
 
-  o_c_file_ptr_stream (FILE* f, c_file_ptr_buf::close_fcn cf = ::fclose)
+  o_c_file_ptr_stream (FILE* f,
+		       c_file_ptr_buf::close_fcn cf = c_file_ptr_buf::fclose)
     : std::ostream (0), buf (new c_file_ptr_buf (f, cf)) { init (buf); }
 
   ~o_c_file_ptr_stream (void) { delete buf; buf = 0; }