(nnheader-replace-chars-in-string nameuid ?. ?/)
nnmail-pathname-coding-system)
dir))))
- (if (and (file-exists-p oldfile)
- (not (file-exists-p newfile)))
- (progn
- (message "nnimap: Upgrading novcache filename...")
- (sit-for 1)
- (gnus-make-directory (file-name-directory newfile))
- (unless (rename-file oldfile newfile)
- (when (copy-file oldfile newfile)
- (delete-file oldfile)))
- newfile)
- newfile)))
+ (when (and (file-exists-p oldfile) (not (file-exists-p newfile)))
+ (message "nnimap: Upgrading novcache filename...")
+ (sit-for 1)
+ (gnus-make-directory (file-name-directory newfile))
+ (unless (ignore-errors (rename-file oldfile newfile) t)
+ (if (ignore-errors (copy-file oldfile newfile) t)
+ (delete-file oldfile)
+ (error "Can't rename `%s' to `%s'" oldfile newfile))))
+ newfile))
(defun nnimap-retrieve-headers-from-file (group server)
(with-current-buffer nntp-server-buffer