changeset 39471:3ca0c12d72fe

(tar-mode-write-file): Don't signal an error by calling byte-to-position with a nil tar-header-offset.
author Gerd Moellmann <gerd@gnu.org>
date Thu, 27 Sep 2001 08:11:36 +0000
parents 3411e4da792d
children c3d9922b855a
files lisp/tar-mode.el
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/tar-mode.el	Wed Sep 26 19:55:41 2001 +0000
+++ b/lisp/tar-mode.el	Thu Sep 27 08:11:36 2001 +0000
@@ -1245,8 +1245,9 @@
 	;; tar-header-offset turns out to be null for files fetched with W3,
 	;; at least.
 	(let ((coding-system-for-write 'no-conversion))
-	  (write-region (or (byte-to-position tar-header-offset)
-			    (point-min))
+	  (write-region (if tar-header-offset
+			    (byte-to-position tar-header-offset)
+			  (point-min))
 			(point-max)
 			buffer-file-name nil t))
 	(tar-clear-modification-flags)