[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fwd: url-cookie.el generating excess backup files
From: |
Stefan Monnier |
Subject: |
Re: Fwd: url-cookie.el generating excess backup files |
Date: |
Tue, 11 Jul 2006 11:11:47 -0400 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
> Would someone who understands URL please figure out if this is
> correct, and DTRT, then ack?
I've installed a slight modification of it.
Thank you Andreas. BTW, I believe you do not have signed papers and this is
your second (small) patch. I think you should consider signing the legal
paperwork so we don't get into trouble next time you submit a patch.
Stefan
> ------- Start of forwarded message -------
> From: Andreas Seltenreich <address@hidden>
> To: address@hidden
> Date: Fri, 07 Jul 2006 23:51:58 +0200
> MIME-Version: 1.0
> Content-Type: text/plain; charset=us-ascii
> Subject: url-cookie.el generating excess backup files
> X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=failed
> version=3.0.4
> IMHO url-cookie.el shouldn't create any backup files when it is
> periodically saving its cookies to disk. If enough backup versions
> accumulate, it triggers the prompt for deleting excess backup files in
> backup-buffer every url-cookie-save-interval seconds, which is quite
> annoying.
> Additionally, it is setting url-cookies-changed-since-last-save on the
> first request, but not resetting the variable anywhere. I don't think
> this is intentional.
> In the suggested patch, I also switched the custom group of
> url-cookie-save-interval, as it looks weird as a lone url-cookie
> option in the parent group.
> Thanks,
> andreas
> 2006-07-04 Andreas Seltenreich <address@hidden>
> * url-cookie.el (url-cookie-write-file): Avoid backup files, reset
> url-cookies-changed-since-last-save.
> (url-cookie-save-interval): Move to url-cookie custom group.
> Index: lisp/url/url-cookie.el
> ===================================================================
> RCS file: /sources/emacs/emacs/lisp/url/url-cookie.el,v
> retrieving revision 1.17
> diff -c -p -r1.17 url-cookie.el
> *** lisp/url/url-cookie.el 5 Jan 2006 22:10:47 -0000 1.17
> - --- lisp/url/url-cookie.el 7 Jul 2006 21:05:06 -0000
> *************** telling Microsoft that."
> *** 168,175 ****
> (insert ")\n(setq url-cookie-secure-storage\n '")
> (pp url-cookie-secure-storage (current-buffer))
> (insert ")\n")
> ! (write-file fname)
> ! (kill-buffer (current-buffer))))))
> (defun url-cookie-store (name value &optional expires domain localpart
> secure)
> "Store a netscape-style cookie."
> - --- 168,177 ----
> (insert ")\n(setq url-cookie-secure-storage\n '")
> (pp url-cookie-secure-storage (current-buffer))
> (insert ")\n")
> ! (let ((backup-inhibited t))
> ! (write-file fname))
> ! (kill-buffer (current-buffer))
> ! (setq url-cookies-changed-since-last-save nil)))))
> (defun url-cookie-store (name value &optional expires domain localpart
> secure)
> "Store a netscape-style cookie."
> *************** to run the `url-cookie-setup-save-timer'
> *** 453,459 ****
> (if (bound-and-true-p url-setup-done)
> (url-cookie-setup-save-timer)))
> :type 'integer
> ! :group 'url)
> (defun url-cookie-setup-save-timer ()
> "Reset the cookie saver timer."
> - --- 455,461 ----
> (if (bound-and-true-p url-setup-done)
> (url-cookie-setup-save-timer)))
> :type 'integer
> ! :group 'url-cookie)
> (defun url-cookie-setup-save-timer ()
> "Reset the cookie saver timer."
> _______________________________________________
> emacs-pretest-bug mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug
> ------- End of forwarded message -------
> _______________________________________________
> Emacs-devel mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/emacs-devel