changeset 17549:a646665cd574

eliminate unecessary static function in urlwrite.cc * urlwrite.cc (cleanup_urlwrite): Delete. (Furlwrite): Use octave_unlink instead of cleanup_urlwrite.
author John W. Eaton <jwe@octave.org>
date Wed, 02 Oct 2013 23:52:28 -0400
parents 92541ff4cc3c
children 77127a3badaa
files libinterp/dldfcn/urlwrite.cc
diffstat 1 files changed, 2 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/libinterp/dldfcn/urlwrite.cc	Wed Oct 02 23:40:01 2013 -0400
+++ b/libinterp/dldfcn/urlwrite.cc	Wed Oct 02 23:52:28 2013 -0400
@@ -828,12 +828,6 @@
 ch_manager *ch_manager::instance = 0;
 
 static void
-cleanup_urlwrite (std::string filename)
-{
-  octave_unlink (filename);
-}
-
-static void
 reset_path (const curl_object& curl)
 {
   curl.cwd ("..");
@@ -844,6 +838,7 @@
 {
   octave_unlink (file);
 }
+
 #endif
 
 DEFUN_DLD (urlwrite, args, nargout,
@@ -974,7 +969,7 @@
 
   unwind_protect_safe frame;
 
-  frame.add_fcn (cleanup_urlwrite, filename);
+  frame.add_fcn (delete_file, filename);
 
   bool ok;
   curl_object curl = curl_object (url, method, param, ofile, ok);