mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-04 11:40:22 +00:00
Kill jobs that we remove from the queue
* url-queue.el (url-queue-kill-job): Refactored out code. (url-queue-remove-jobs-from-host): Use it to kill jobs that are in flight.
This commit is contained in:
parent
6546b13405
commit
f15bcb40f4
@ -1,3 +1,9 @@
|
|||||||
|
2012-02-14 Lars Ingebrigtsen <larsi@gnus.org>
|
||||||
|
|
||||||
|
* url-queue.el (url-queue-kill-job): Refactored out code.
|
||||||
|
(url-queue-remove-jobs-from-host): Use it to kill jobs that are in
|
||||||
|
flight.
|
||||||
|
|
||||||
2012-02-14 Teodor Zlatanov <tzz@lifelogs.com>
|
2012-02-14 Teodor Zlatanov <tzz@lifelogs.com>
|
||||||
|
|
||||||
* url-future.el: Minor doc update.
|
* url-future.el: Minor doc update.
|
||||||
|
@ -127,6 +127,7 @@ The variable `url-queue-timeout' sets a timeout."
|
|||||||
host)
|
host)
|
||||||
(push job jobs)))
|
(push job jobs)))
|
||||||
(dolist (job jobs)
|
(dolist (job jobs)
|
||||||
|
(url-queue-kill-job job)
|
||||||
(setq url-queue (delq job url-queue)))))
|
(setq url-queue (delq job url-queue)))))
|
||||||
|
|
||||||
(defun url-queue-start-retrieve (job)
|
(defun url-queue-start-retrieve (job)
|
||||||
@ -146,14 +147,17 @@ The variable `url-queue-timeout' sets a timeout."
|
|||||||
url-queue-timeout))
|
url-queue-timeout))
|
||||||
(push job dead-jobs)))
|
(push job dead-jobs)))
|
||||||
(dolist (job dead-jobs)
|
(dolist (job dead-jobs)
|
||||||
(when (bufferp (url-queue-buffer job))
|
(url-queue-kill-job job)
|
||||||
(while (get-buffer-process (url-queue-buffer job))
|
|
||||||
(ignore-errors
|
|
||||||
(delete-process (get-buffer-process (url-queue-buffer job)))))
|
|
||||||
(ignore-errors
|
|
||||||
(kill-buffer (url-queue-buffer job))))
|
|
||||||
(setq url-queue (delq job url-queue)))))
|
(setq url-queue (delq job url-queue)))))
|
||||||
|
|
||||||
|
(defun url-queue-kill-job (job)
|
||||||
|
(when (bufferp (url-queue-buffer job))
|
||||||
|
(while (get-buffer-process (url-queue-buffer job))
|
||||||
|
(ignore-errors
|
||||||
|
(delete-process (get-buffer-process (url-queue-buffer job)))))
|
||||||
|
(ignore-errors
|
||||||
|
(kill-buffer (url-queue-buffer job)))))
|
||||||
|
|
||||||
(provide 'url-queue)
|
(provide 'url-queue)
|
||||||
|
|
||||||
;;; url-queue.el ends here
|
;;; url-queue.el ends here
|
||||||
|
Loading…
Reference in New Issue
Block a user