Commit 18740c97 authored by David Kågedal's avatar David Kågedal
Browse files

Lite kod som kanske hjälper för att hitta buggar.

parent 5fc249ff
No preview for this file type
......@@ -59,6 +59,8 @@ Allm
Å K - Återse den text som den föregående texten kommenterade
Återinför Olästa
text 1306827
Varför står det "anonym person" på ett ställe, men "Person 0" på
ett annat? Och vad menar Rickard?
......
......@@ -922,7 +922,7 @@ Format is 23:29 if the text is written today. Otherwise 04-01."
(interactive)
(let* ((curbuf (current-buffer))
(old-buf (condition-case ()
debugger-old-buffer
(or debugger-old-buffer (current-buffer))
(void-variable (current-buffer))))
(repname "*lyskom-bugreport*"))
(lyskom-message "%s" (lyskom-get-string 'buggreport-compilestart))
......
No preview for this file type
......@@ -155,24 +155,31 @@ Value returned is always nil."
"Return from blocking-do-multiple")
(defun lyskom-blocking-do-multiple (call-list)
(let ((lyskom-multiple-blocking-return 'not-yet-gotten))
(lyskom-collect 'blocking)
(while call-list
(apply (intern-soft (concat "initiate-"
(symbol-name (car (car call-list)))))
'blocking nil
(cdr (car call-list)))
(setq call-list (cdr call-list)))
(lyskom-use 'blocking 'lyskom-blocking-do-multiple-1)
(while (and (eq lyskom-multiple-blocking-return 'not-yet-gotten)
(not lyskom-quit-flag))
(accept-process-output nil lyskom-apo-timeout-s lyskom-apo-timeout-ms))
(if lyskom-quit-flag
(progn
(setq lyskom-quit-flag nil)
(lyskom-insert-before-prompt (lyskom-get-string 'interrupted))
(signal 'quit nil)))
lyskom-multiple-blocking-return))
(save-excursion
(set-buffer (process-buffer (or lyskom-proc
lyskom-blocking-process)))
;; If this happens, we're in trouble
(if lyskom-is-parsing
(lyskom-really-serious-bug))
(let ((lyskom-multiple-blocking-return 'not-yet-gotten))
(lyskom-collect 'blocking)
(while call-list
(apply (intern-soft (concat "initiate-"
(symbol-name (car (car call-list)))))
'blocking nil
(cdr (car call-list)))
(setq call-list (cdr call-list)))
(lyskom-use 'blocking 'lyskom-blocking-do-multiple-1)
(while (and (eq lyskom-multiple-blocking-return 'not-yet-gotten)
(not lyskom-quit-flag))
(accept-process-output nil lyskom-apo-timeout-s lyskom-apo-timeout-ms))
(if lyskom-quit-flag
(progn
(setq lyskom-quit-flag nil)
(lyskom-insert-before-prompt (lyskom-get-string 'interrupted))
(signal 'quit nil)))
lyskom-multiple-blocking-return)))
(defun lyskom-blocking-do-multiple-1 (&rest data)
(setq lyskom-multiple-blocking-return data))
......
......@@ -683,9 +683,14 @@ The cache is consulted when command is get-conf-stat, get-pers-stat
or get-text-stat."
;; Here we could check if lyskom-blocking-return is non-nil, in
;; which case there is a bug in the code
(save-excursion
(set-buffer (process-buffer (or lyskom-proc
lyskom-blocking-process)))
;; If this happens, we're in trouble
(if lyskom-is-parsing
(lyskom-really-serious-bug))
(let ((lyskom-blocking-return 'not-yet-gotten))
(apply (intern-soft (concat "initiate-"
(symbol-name command)))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment