X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/4f8a4547454e24304b4182fbf4ae4b34a7bdc92b..3698c4e475fb59730626af5d001599785ef5ef9e:/lisp/jka-compr.el diff --git a/lisp/jka-compr.el b/lisp/jka-compr.el index cd769885cc..a5556743eb 100644 --- a/lisp/jka-compr.el +++ b/lisp/jka-compr.el @@ -1,9 +1,10 @@ ;;; jka-compr.el --- reading/writing/loading compressed files -;; Copyright (C) 1993-1995, 1997, 1999-2011 Free Software Foundation, Inc. +;; Copyright (C) 1993-1995, 1997, 1999-2016 Free Software Foundation, +;; Inc. -;; Author: jka@ece.cmu.edu (Jay K. Adams) -;; Maintainer: FSF +;; Author: Jay K. Adams +;; Maintainer: emacs-devel@gnu.org ;; Keywords: data ;; This file is part of GNU Emacs. @@ -108,8 +109,7 @@ data appears to be compressed already.") (put 'jka-compr-really-do-compress 'permanent-local t) -(put 'compression-error 'error-conditions '(compression-error file-error error)) - +(define-error 'compression-error nil 'file-error) (defvar jka-compr-acceptable-retval-list '(0 2 141)) @@ -203,6 +203,7 @@ to keep: LEN chars starting BEG chars from the beginning." ;; call-process barfs if default-directory is inaccessible. (let ((default-directory (if (and default-directory + (not (file-remote-p default-directory)) (file-accessible-directory-p default-directory)) default-directory (file-name-directory infile)))) @@ -330,8 +331,6 @@ There should be no more than seven characters after the final `/'." (with-current-buffer temp-buffer (let ((coding-system-for-write 'no-conversion)) - (if (memq system-type '(ms-dos windows-nt)) - (setq buffer-file-type t) ) (jka-compr-run-real-handler 'write-region (list (point-min) (point-max) filename @@ -657,16 +656,15 @@ It is not recommended to set this variable permanently to anything but nil.") (defun jka-compr-uninstall () "Uninstall jka-compr. This removes the entries in `file-name-handler-alist' and `auto-mode-alist' -and `inhibit-first-line-modes-suffixes' that were added +and `inhibit-local-variables-suffixes' that were added by `jka-compr-installed'." - ;; Delete from inhibit-first-line-modes-suffixes - ;; what jka-compr-install added. + ;; Delete from inhibit-local-variables-suffixes what jka-compr-install added. (mapc (function (lambda (x) (and (jka-compr-info-strip-extension x) - (setq inhibit-first-line-modes-suffixes + (setq inhibit-local-variables-suffixes (delete (jka-compr-info-regexp x) - inhibit-first-line-modes-suffixes))))) + inhibit-local-variables-suffixes))))) jka-compr-compression-info-list--internal) (let* ((fnha (cons nil file-name-handler-alist))