From 5794064c2c86e158f916f3bd3568b75a8c78bc22 Mon Sep 17 00:00:00 2001
From: Andreas Kupries <andreas_kupries@users.sourceforge.net>
Date: Sun, 4 Jul 2004 23:41:54 +0000
Subject: [PATCH] 	* library/vfsUtils.tcl (crc, zip): Modified the Trf
 adapter 	  commands. They are now adding in a "--" before the last
 argument 	  they get, to ensure its interpretation as data instead of
 being 	  misinterpreted as option should it begin with a dash. Without 
   this adding a file beginning with a dash to a filesystem will 	 
 fail.

---
 ChangeLog            | 9 +++++++++
 library/vfsUtils.tcl | 4 ++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index caa981e..97c2553 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2004-07-04  Andreas Kupries <andreas_kupries@users.sourceforge.net>
+	
+	* library/vfsUtils.tcl (crc, zip): Modified the Trf adapter
+	  commands. They are now adding in a "--" before the last argument
+	  they get, to ensure its interpretation as data instead of being
+	  misinterpreted as option should it begin with a dash. Without
+	  this adding a file beginning with a dash to a filesystem will
+	  fail.
+
 2004-06-29  Vince Darley <vincentdarley@sourceforge.net>
 
 	* library/zipvfs.tcl: fix to bug finding zip header (reported on
diff --git a/library/vfsUtils.tcl b/library/vfsUtils.tcl
index 42d6a9b..a146c2b 100644
--- a/library/vfsUtils.tcl
+++ b/library/vfsUtils.tcl
@@ -21,13 +21,13 @@ proc ::vfs::memchan {args} {
 # This can be overridden to use a different crc implementation
 proc ::vfs::crc {args} {
     ::package require Trf
-    uplevel 1 [list ::crc] $args
+    uplevel 1 [linsert [linsert $args end-1 "--"] 0 ::crc]
 }
 
 # This can be overridden to use a different zip implementation
 proc ::vfs::zip {args} {
     ::package require Trf
-    uplevel 1 [list ::zip] $args
+    uplevel 1 [linsert [linsert $args end-1 "--"] 0 ::zip]
 }
 
 proc ::vfs::autoMountExtension {ext cmd {pkg ""}} {
-- 
2.23.0