(gnus-xmas-group-startup-message): Insert space before "based on".
[elisp/gnus.git-] / lisp / gnus-util.el
index ee18c66..8de7434 100644 (file)
@@ -733,7 +733,7 @@ with potentially long computations."
       ;; Decide whether to append to a file or to an Emacs buffer.
       (let ((outbuf (get-file-buffer filename)))
        (if (not outbuf)
-           (append-to-file (point-min) (point-max) filename)
+           (write-region-as-binary (point-min) (point-max) filename 'append)
          ;; File has been visited, in buffer OUTBUF.
          (set-buffer outbuf)
          (let ((buffer-read-only nil)
@@ -986,7 +986,8 @@ ARG is passed to the first function."
     t))
 
 (static-if (boundp 'MULE)
-    (defun gnus-write-active-file-as-coding-system (coding-system file hashtb)
+    (defun gnus-write-active-file-as-coding-system
+      (coding-system file hashtb &optional full-names)
       (let ((output-coding-system coding-system))
        (with-temp-file file
          (mapatoms
@@ -995,11 +996,15 @@ ARG is passed to the first function."
                        (boundp sym)
                        (symbol-value sym))
               (insert (format "%s %d %d y\n"
-                              (gnus-group-real-name (symbol-name sym))
-                              (cdr (symbol-value sym))
+                              (if full-names
+                                  (symbol-name sym)
+                                (gnus-group-real-name (symbol-name sym)))
+                              (or (cdr (symbol-value sym))
+                                  (car (symbol-value sym)))
                               (car (symbol-value sym))))))
           hashtb))))
-  (defun gnus-write-active-file-as-coding-system (coding-system file hashtb)
+  (defun gnus-write-active-file-as-coding-system
+    (coding-system file hashtb &optional full-names)
     (let ((coding-system-for-write coding-system))
       (with-temp-file file
        (mapatoms
@@ -1008,8 +1013,11 @@ ARG is passed to the first function."
                      (boundp sym)
                      (symbol-value sym))
             (insert (format "%s %d %d y\n"
-                            (gnus-group-real-name (symbol-name sym))
-                            (cdr (symbol-value sym))
+                            (if full-names
+                                (symbol-name sym)
+                              (gnus-group-real-name (symbol-name sym)))
+                            (or (cdr (symbol-value sym))
+                                (car (symbol-value sym)))
                             (car (symbol-value sym))))))
         hashtb))))
   )