Commit 8e0d776a authored by David Kågedal's avatar David Kågedal
Browse files

La in Inges prefetch.el och anpassad resten efter det.

parent 61b846bf
Sun Sep 29 15:21:36 1996 David Kgedal <davidk@lysator.liu.se>
* view-text.el (lyskom-view-text): Prefetcha inlggstrdet.
* startup.el (lyskom): Anropa lyskom-setup-prefetch.
(lyskom-refetch): Anpassa till nya prefetchen.
* prefetch.el (lyskom-inhibit-prefetch): Ny variabel.
(lyskom-setup-prefetch): Stt lyskom-membership-is-read till 0.
(lyskom-prefetch-membership): ...istllet fr hr.
(lyskom-prefetch-map): Ta membership som parameter.
(lyskom-prefetch-map-using-conf-stat): Dito.
(lyskom-prefetch-all-conf-texts): Ny funktion (som inte anvnds).
(lyskom-prefetch-conf-texts): Dito.
(lyskom-continue-prefetch): Anvnd lyskom-inibit-prefetch fr att
frhindra rekursion.
(lyskom-prefetch-one-item): Prefetcha alla texter nr hela
medlemsskapslistan r inlst. Dett r dock bortkopplat just nu,
eftersom det strular.
(lyskom-prefetch-one-request): Skicka med membership-argumentet
vid CONFSTATFORMAP och MAP.
(lyskom-prefetch-membership-handler): Testa om medlemsskapet r
synligt.
(lyskom-prefetch-confstatformap-handler): Ta och skicka
membership.
(lyskom-prefetch-map-handler): Dito. Och gr inte listify-vector i
ondan. Uppdatera prompten.
* lyskom-rest.el (lyskom-what-to-do): Nytt test fr nr
medlemskapet r inlst.
(lyskom-prefetch-and-print-prompt): Gr ingen prefetch. Funktionen
borde byta namn, eller frsvinna.
(lyskom-prefetch-all-confs): Gr ingenting. Detta fr "Lista
nyheter" att bete sig lite lustigt i inledningefasen.
(lyskom-prefetch-all-confs): Anvnd nya prefetchen.
(lyskom-prefetch-conf,lyskom-prefetch-done)
(lyskom-prefetch-handle-conf,lyskom-prefetch-handle-map)
(lyskom-conf-fetched-p,lyskom-prefetch-text)
(lyskom-prefetch-from-rlist,lyskom-prefetch-from-list)
(lyskom-prefetch-comment-stats): Bortkommenterade.
* internal.el (lyskom-apply-handler,lysom-apply-multi-hander)
(lyskom-apply-multi-list-handler): Bind inte inhibit-quit till
nil.
* async.el (lyskom-add-new-text): Anpassad till nya prefetchen.
* Makefile (PARTS-EL): La till prefetch.el
* En hel del ndringar i prefetch-koden gjordes tidigare, men jag
skriver in den i ChangeLog nu.
Fri Sep 27 01:47:13 1996 David Kgedal <davidk@lysator.liu.se>
* commands1.el (lyskom-add-membership): Anvnd prefetch fr att
hmta mappen istllet.
Thu Sep 26 00:08:32 1996 David Kgedal <davidk@lysator.liu.se>
* lyskom-rest.el (lyskom-end-of-command): Se till att de saker som
skrivs ut innan prompten brjar en ny rad.
* services.el (blocking-do): Strunta i att fnga quit.
* macros.el (def-kom-command): Fnga quit, och skriv ut "Kommandot
avbrutet".
* parse.el (lyskom-parse-unparsed): Bind inte inhibit-quit till
nil.
* lyskom-rest.el (lyskom-filter): Testa om quit-flag r satt nr
funktionen avslutas, och stt i s fall lyskom-quit-flag.
* internal.el (lyskom-apply-handler): Bind inte inhibit-quit till
nil.
(lyskom-apply-multi-handler): Dito.
(lyskom-apply-multi-list-handler): Dito.
* reading.el (lyskom-enter-map-in-to-do-list): Anvnd
lyskom-list-unread.
Wed Sep 25 13:32:48 1996 David Kgedal <davidk@lysator.liu.se>
* clienttypes.el (read-list-enter-read-info): Om mtet redan fanns
med i rlist, lgg till texterna p slutet i den read-infon
istllet fr att lgga till den nya read-infon separat.
(read-info-append-text-list): Ny funktion.
(read-info-enter-text-last): Ny funktion.
(read-list-enter-text): Anvnd den.
Wed Sep 25 12:14:48 1996 David Byers <davby@sen2.ida.liu.se> Wed Sep 25 12:14:48 1996 David Byers <davby@sen2.ida.liu.se>
* english-strings.el, swedish-strings.el (lyskom-strings): Anvnd * english-strings.el, swedish-strings.el (lyskom-strings): Anvnd
......
...@@ -51,6 +51,7 @@ PARTS-EL = komtypes.el clienttypes.el deferred-insert.el utilities.el \ ...@@ -51,6 +51,7 @@ PARTS-EL = komtypes.el clienttypes.el deferred-insert.el utilities.el \
view-text.el async.el completing-read.el \ view-text.el async.el completing-read.el \
prioritize.el flags.el messages.el ansaphone.el remote-control.el \ prioritize.el flags.el messages.el ansaphone.el remote-control.el \
slow.el \ slow.el \
prefetch.el \
elib-string.el \ elib-string.el \
lyskom-rest.el lyskom-rest.el
HEADER-EL = vars.el macros.el HEADER-EL = vars.el macros.el
...@@ -67,7 +68,7 @@ SRC-ELC = komtypes.elc clienttypes.elc deferred-insert.elc utilities.elc \ ...@@ -67,7 +68,7 @@ SRC-ELC = komtypes.elc clienttypes.elc deferred-insert.elc utilities.elc \
filter.elc filter-edit.elc lyskom-buttons.elc \ filter.elc filter-edit.elc lyskom-buttons.elc \
view-text.elc async.elc completing-read.elc \ view-text.elc async.elc completing-read.elc \
prioritize.elc flags.elc messages.elc ansaphone.elc \ prioritize.elc flags.elc messages.elc ansaphone.elc \
remote-control.elc slow.elc elib-string.elc \ remote-control.elc slow.elc prefetch.elc elib-string.elc \
lyskom-rest.elc lyskom-rest.elc
PARTS-ELC = $(SRC-ELC) PARTS-ELC = $(SRC-ELC)
......
...@@ -3,6 +3,11 @@ Att g ...@@ -3,6 +3,11 @@ Att g
Buggar Buggar
Lista nyheter visar fel innan prefetchen har hämtat alla mappar.
Efter återse senaste fick jag fel prompt. Jag vill ha återse
nästa-prompten direkt om det finns texter som matchar villkoret.
lyskom-read-session-no hanterar inte att man anger specifikt lyskom-read-session-no hanterar inte att man anger specifikt
sessionsnummer om samma person har flera sessioner, tror jag. sessionsnummer om samma person har flera sessioner, tror jag.
Problemet är att s xxxx hanteras i lyskom-read-conf-internal som Problemet är att s xxxx hanteras i lyskom-read-conf-internal som
......
...@@ -479,20 +479,27 @@ In that case, just discard this call." ...@@ -479,20 +479,27 @@ In that case, just discard this call."
;; Update the read-lists. ;; Update the read-lists.
(if (and (lyskom-conf-fetched-p (conf-stat->conf-no recipient)) ;; Prefetch thoughts:
(lyskom-visible-membership ;; We need a way to check if a conferences is fetched.
(lyskom-member-p (conf-stat->conf-no recipient))) ;; davidk /960924
(not (read-list-enter-text text-no recipient lyskom-to-do-list)))
;; If we have already read all texts in the conference... (let ((member (lyskom-member-p (conf-stat->conf-no recipient))))
(let ((info (lyskom-create-read-info (if (and member
'CONF ;; (lyskom-conf-fetched-p (conf-stat->conf-no recipient))
recipient (lyskom-visible-membership member)
(membership->priority (not (read-list-enter-text text-no recipient
(lyskom-member-p (conf-stat->conf-no recipient))) lyskom-to-do-list)))
(lyskom-create-text-list (list text-no))))) ;; If we have already read all texts in the conference or the
(read-list-enter-read-info info lyskom-to-do-list) ;; text has not been prefetched
(if (= lyskom-current-conf (conf-stat->conf-no recipient)) (let ((info (lyskom-create-read-info
(read-list-enter-first info lyskom-reading-list)))) 'CONF
recipient
(membership->priority
(lyskom-member-p (conf-stat->conf-no recipient)))
(lyskom-create-text-list (list text-no)))))
(read-list-enter-read-info info lyskom-to-do-list)
(if (= lyskom-current-conf (conf-stat->conf-no recipient))
(read-list-enter-first info lyskom-reading-list)))))
(lyskom-set-mode-line)))) (lyskom-set-mode-line))))
......
...@@ -143,6 +143,15 @@ ...@@ -143,6 +143,15 @@
(eq (car-safe object) 'READ-INFO)) (eq (car-safe object) 'READ-INFO))
(defsubst read-info-append-text-list (read-info texts)
(set-read-info->text-list
read-info
(nconc (read-info->text-list read-info)
texts)))
(defsubst read-info-enter-text-last (read-info text-no)
(read-info-append-text-list read-info (list text-no)))
;;; ================================================================ ;;; ================================================================
;;; read-list ;;; read-list
...@@ -218,10 +227,7 @@ Returns t if there was a conference to insert this text into." ...@@ -218,10 +227,7 @@ Returns t if there was a conference to insert this text into."
((and (eq 'CONF (read-info->type read-info)) ((and (eq 'CONF (read-info->type read-info))
(= (conf-stat->conf-no recipient) (= (conf-stat->conf-no recipient)
(conf-stat->conf-no (read-info->conf-stat read-info)))) (conf-stat->conf-no (read-info->conf-stat read-info))))
(set-read-info->text-list (read-info-enter-text-last read-info text-no)
read-info
(nconc (read-info->text-list read-info)
(list text-no)))
(setq inserted t)))) (setq inserted t))))
inserted)) inserted))
...@@ -265,10 +271,23 @@ will nomally be inserted after the old one, but if BEFORE is non-nil it ...@@ -265,10 +271,23 @@ will nomally be inserted after the old one, but if BEFORE is non-nil it
will be inserted before it." will be inserted before it."
(let ((pri (+ (if before 0 -1) (let ((pri (+ (if before 0 -1)
(read-info->priority read-info))) (read-info->priority read-info)))
(continue t)) (continue t)
(conf-stat (read-info->conf-stat read-info))
(type (read-info->type read-info)))
(while continue (while continue
(cond (cond
((null (cdr rlist)) ;; This case was added by davidk 960925. It is not used from
;; everywhere, but at least lyskom-enter-map-in-to-do-list
;; should become more efficient.
((and (eq type 'CONF)
(eq (read-info->type (car (cdr rlist))) 'CONF)
(eq conf-stat (read-info->conf-stat (car (cdr rlist)))))
(read-info-append-text-list
(car (cdr rlist))
(text-list->texts (read-info->text-list read-info)))
(setq continue nil))
((null (cdr rlist))
(setcdr rlist (list read-info)) (setcdr rlist (list read-info))
(setq continue nil)) (setq continue nil))
((>= pri (read-info->priority (car (cdr rlist)))) ((>= pri (read-info->priority (car (cdr rlist))))
......
...@@ -415,26 +415,30 @@ Also adds to lyskom-to-do-list." ...@@ -415,26 +415,30 @@ Also adds to lyskom-to-do-list."
(progn (progn
(setq lyskom-membership (sort (cons membership lyskom-membership) (setq lyskom-membership (sort (cons membership lyskom-membership)
'lyskom-membership-<)) 'lyskom-membership-<))
(let ((map (blocking-do ;; (let ((map (blocking-do
'get-map ;; 'get-map
(conf-stat->conf-no conf-stat) ;; (conf-stat->conf-no conf-stat)
(max (1+ (membership->last-text-read membership)) ;; (max (1+ (membership->last-text-read membership))
(conf-stat->first-local-no conf-stat)) ;; (conf-stat->first-local-no conf-stat))
(conf-stat->no-of-texts conf-stat)))) ;; (conf-stat->no-of-texts conf-stat))))
(if map ;; (if map
(let ((texts (skip-first-zeros ;; (let ((texts (skip-first-zeros
(sort (listify-vector (map->text-nos map)) ;; (sort (listify-vector (map->text-nos map))
'<)))) ;; '<))))
(if texts ;; (if texts
(read-list-enter-read-info ;; (read-list-enter-read-info
(lyskom-create-read-info ;; (lyskom-create-read-info
'CONF conf-stat ;; 'CONF conf-stat
(membership->priority membership) ;; (membership->priority membership)
(lyskom-create-text-list ;; (lyskom-create-text-list
texts) ;; texts)
nil nil) ;; nil nil)
lyskom-to-do-list)))) ;; lyskom-to-do-list))))
)) ;; )
(lyskom-prefetch-map-using-conf-stat
conf-stat
(1+ (membership->last-text-read membership))
membership))
(lyskom-insert-string 'conf-does-not-exist)) (lyskom-insert-string 'conf-does-not-exist))
) )
......
...@@ -555,39 +555,30 @@ RUN -> call function. Delete. Not allowed inside COLLECT/USE." ...@@ -555,39 +555,30 @@ RUN -> call function. Delete. Not allowed inside COLLECT/USE."
(lyskom-queue-delete-first (kom-queue->pending queue)) (lyskom-queue-delete-first (kom-queue->pending queue))
(setq first-pending (lyskom-queue->first (kom-queue->pending queue)))))) (setq first-pending (lyskom-queue->first (kom-queue->pending queue))))))
;;; Quit is ok to press while the handler is running but we should catch it ;;; Quit is NOT ok to press while the handler is running. inhibit-quit
;;; here ;;; should be t when these are called.
(defun lyskom-apply-handler (pending) (defun lyskom-apply-handler (pending)
"Apply a handler. Args: PENDING. "Apply a handler. Args: PENDING.
PENDING is an entry of the list as described in documentation for the variable PENDING is an entry of the list as described in documentation for the variable
lyskom-call-data. The car on the list must be a PARSED: lyskom-call-data. The car on the list must be a PARSED:
('PARSED RESULT HANDLER HANDLER-DATA)" ('PARSED RESULT HANDLER HANDLER-DATA)"
(let ((inhibit-quit nil)) (if (car (cdr (cdr pending)))
(condition-case error (apply (car (cdr (cdr pending))) ;Handler
(if (car (cdr (cdr pending))) (car (cdr pending)) ;Result
(apply (car (cdr (cdr pending))) ;Handler (car (cdr (cdr (cdr pending))))))) ;Handler-data
(car (cdr pending)) ;Result
(car (cdr (cdr (cdr pending)))))) ;Handler-data
(quit (beep)))))
(defun lyskom-apply-multi-handler (pending result-list) (defun lyskom-apply-multi-handler (pending result-list)
"Apply a handler for a lyskom-collect - lyskom-use construct." "Apply a handler for a lyskom-collect - lyskom-use construct."
(let ((inhibit-quit nil)) (apply (car (cdr pending)) ;Multi-handler
(condition-case error (nconc result-list
(apply (car (cdr pending)) ;Multi-handler (car (cdr (cdr pending)))))) ;Multi-handler-data
(nconc result-list
(car (cdr (cdr pending))))) ;Multi-handler-data
(quit (beep)))))
(defun lyskom-apply-multi-list-handler (pending result-list) (defun lyskom-apply-multi-list-handler (pending result-list)
"Apply a handler for a lyskom-collect - lyskom-list-use construct." "Apply a handler for a lyskom-collect - lyskom-list-use construct."
(let ((inhibit-quit nil)) (apply (car (cdr pending)) ;Multi-handler
(condition-case error (cons result-list
(apply (car (cdr pending)) ;Multi-handler (car (cdr (cdr pending)))))) ;Multi-handler-data
(cons result-list
(car (cdr (cdr pending))))) ;Multi-handler-data
(quit (beep)))))
(defun lyskom-apply-function (pending) (defun lyskom-apply-function (pending)
(setcar pending 'HALTED) (setcar pending 'HALTED)
......
No preview for this file type
...@@ -130,8 +130,14 @@ Value returned is always nil." ...@@ -130,8 +130,14 @@ Value returned is always nil."
(list 'defun cmd args doc interactive-decl (list 'defun cmd args doc interactive-decl
(list 'lyskom-start-of-command (list 'quote cmd)) (list 'lyskom-start-of-command (list 'quote cmd))
(list 'unwind-protect (list 'unwind-protect
(cons 'progn (list 'condition-case 'error
forms) (cons 'progn
forms)
(list 'quit
(list 'ding)
(list 'lyskom-insert-before-prompt
(list 'lyskom-get-string
(list 'quote 'interrupted)))))
(list 'lyskom-end-of-command)))) (list 'lyskom-end-of-command))))
......
...@@ -118,7 +118,9 @@ Signal lyskom-protocol-error if the next token is not a number." ...@@ -118,7 +118,9 @@ Signal lyskom-protocol-error if the next token is not a number."
(goto-char lyskom-parse-pos) (goto-char lyskom-parse-pos)
(let* ((max (point-max)) (let* ((max (point-max))
(result (condition-case read-error (result (condition-case read-error
(read (current-buffer)) ;; Eval it to prevent malfunction when
;; edebug-all-defs or edebug-all-forms is non-nil.
(read (current-buffer))
(end-of-file (signal 'lyskom-parse-incomplete nil)))) (end-of-file (signal 'lyskom-parse-incomplete nil))))
(pos (point))) (pos (point)))
(cond (cond
...@@ -907,7 +909,9 @@ functions and variables that are connected with the lyskom-buffer." ...@@ -907,7 +909,9 @@ functions and variables that are connected with the lyskom-buffer."
(let* ((lyskom-parse-pos 1) (let* ((lyskom-parse-pos 1)
(key (lyskom-parse-nonwhite-char))) (key (lyskom-parse-nonwhite-char)))
(condition-case err (condition-case err
(let ((inhibit-quit nil)) (let ((inhibit-quit t)) ; Used to be nil, but that can
; cause hard-to-repair
; problems
(cond (cond
((eq key ?=) ;The call succeeded. ((eq key ?=) ;The call succeeded.
(lyskom-parse-success (lyskom-parse-num) lyskom-buffer)) (lyskom-parse-success (lyskom-parse-num) lyskom-buffer))
......
...@@ -86,7 +86,9 @@ lyskom-queue. ...@@ -86,7 +86,9 @@ lyskom-queue.
are done. are done.
For every membership-part we fetch the conf-stats For every membership-part we fetch the conf-stats
before continuing with the next part. before continuing with the next part.
(MEMBERSHIPISREAD) - Just sets the lyskom-membership-is-read variable to t. ('MEMBERSHIPISREAD) - Just sets the lyskom-membership-is-read variable to t.
('ALL-CONF-TEXTS) - All text in all conferences.
('CONF-TEXTS) - All text in one conference.
See further documentation in the source code.") See further documentation in the source code.")
...@@ -119,6 +121,11 @@ See further documentation in the source code.") ...@@ -119,6 +121,11 @@ See further documentation in the source code.")
"t when the prefetch-process is started and going.") "t when the prefetch-process is started and going.")
(defvar lyskom-inhibit-prefetch nil
"Set this to a non-nil value locally to inhibit the prefetch.
This is used to prevent the prefetch code to reenter itself.")
(defvar lyskom-pending-prefetch 0 (defvar lyskom-pending-prefetch 0
"Variable counting the number of unfinished prefetch requests.") "Variable counting the number of unfinished prefetch requests.")
...@@ -140,7 +147,8 @@ at a time.") ...@@ -140,7 +147,8 @@ at a time.")
"Sets up the prefetch process in lyskom." "Sets up the prefetch process in lyskom."
;+++ Much more could be done here. ;+++ Much more could be done here.
(setq lyskom-prefetch-stack (lyskom-stack-create)) (setq lyskom-prefetch-stack (lyskom-stack-create))
(setq lyskom-pending-prefetch 0)) (setq lyskom-pending-prefetch 0)
(setq lyskom-membership-is-read 0))
(defun lyskom-prefetch-conf (conf-no &optional queue) (defun lyskom-prefetch-conf (conf-no &optional queue)
...@@ -225,22 +233,25 @@ lyskom-prefetch-stack." ...@@ -225,22 +233,25 @@ lyskom-prefetch-stack."
(lyskom-continue-prefetch)) (lyskom-continue-prefetch))
(defun lyskom-prefetch-map (conf-no first-local &optional queue) (defun lyskom-prefetch-map (conf-no first-local membership &optional queue)
"Prefetches a map for conf CONFNO starting att FIRST-LOCAL." "Prefetches a map for conf CONFNO starting att FIRST-LOCAL."
(if queue (if queue
(lyskom-queue-enter queue (list 'CONFSTATFORMAP conf-no first-local)) (lyskom-queue-enter queue (list 'CONFSTATFORMAP
(lyskom-stack-push lyskom-prefetch-stack (list 'CONFSTATFORMAP conf-no first-local membership))
conf-no first-local))) (lyskom-stack-push lyskom-prefetch-stack
(list 'CONFSTATFORMAP
conf-no first-local membership)))
(lyskom-continue-prefetch)) (lyskom-continue-prefetch))
(defun lyskom-prefetch-map-using-conf-stat (conf-stat first-local (defun lyskom-prefetch-map-using-conf-stat (conf-stat first-local membership
&optional queue) &optional queue)
"Prefetches a map for conf CONFSTAT starting att FIRST-LOCAL." "Prefetches a map for conf CONFSTAT starting att FIRST-LOCAL."
(if queue (if queue
(lyskom-queue-enter queue (list 'MAP conf-stat first-local)) (lyskom-queue-enter queue (list 'MAP conf-stat first-local membership))
(lyskom-stack-push lyskom-prefetch-stack (list 'MAP (lyskom-stack-push lyskom-prefetch-stack (list 'MAP
conf-stat first-local))) conf-stat first-local
membership)))
(lyskom-continue-prefetch)) (lyskom-continue-prefetch))
...@@ -265,6 +276,24 @@ lyskom-prefetch-stack." ...@@ -265,6 +276,24 @@ lyskom-prefetch-stack."
(lyskom-continue-prefetch)) (lyskom-continue-prefetch))
(defun lyskom-prefetch-all-conf-texts (&optional queue)
"Prefetches the texts in all conferences."
(if queue
(lyskom-queue-enter queue (list 'ALL-CONF-TEXTS))
(lyskom-stack-push lyskom-prefetch-stack (list 'ALL-CONF-TEXTS)))
(lyskom-continue-prefetch))
(defun lyskom-prefetch-conf-texts (text-list &optional queue)
"Prefetches the texts in all conferences."
(if (null (text-list->texts text-list))
nil
(if queue
(lyskom-queue-enter queue (list 'CONF-TEXTS text-list))
(lyskom-stack-push lyskom-prefetch-stack (list 'CONF-TEXTS text-list))))
(lyskom-continue-prefetch))
;;; ================================================================ ;;; ================================================================
;;; Functions internal to the prefetch package ;;; Functions internal to the prefetch package
...@@ -283,14 +312,20 @@ lyskom-prefetch-stack." ...@@ -283,14 +312,20 @@ lyskom-prefetch-stack."
(defun lyskom-continue-prefetch () (defun lyskom-continue-prefetch ()
"Called after each prefetch is finished and also when the whole prefetch "Called after each prefetch is finished and also when the whole prefetch
process is started. Used to keep prefetch going." process is started. Used to keep prefetch going."
(if lyskom-prefetch-in-action (if (not lyskom-inhibit-prefetch)
(let ((lyskom-prefetch-in-action nil)) ; Make sure we don't call this (let ((lyskom-inhibit-prefetch t)) ; Make sure we don't call this
; recursively ; recursively
(while (and (< lyskom-pending-prefetch (while (and (< lyskom-pending-prefetch
lyskom-prefetch-limit) lyskom-prefetch-limit)
(lyskom-prefetch-one-item) (lyskom-prefetch-one-item)
;; Only increase lyskom-pending-prefetch if there ;; Only increase lyskom-pending-prefetch if a server
;; was something to get. ;; call was made.
;;
;; The return value from lyskom-prefetch-one-item
;; is whether it has sent a server call, but it
;; should really be if the prefetch-stack has been
;; altered. See the comment in
;; lyskom-prefetch-one-item.
(++ lyskom-pending-prefetch)))))) (++ lyskom-pending-prefetch))))))
...@@ -360,14 +395,39 @@ Return t if an element was prefetched, otherwise return nil." ...@@ -360,14 +395,39 @@ Return t if an element was prefetched, otherwise return nil."
(lyskom-prefetch-one-request element queue) (lyskom-prefetch-one-request element queue)
(setq result t))) (setq result t)))
;; Special request ;; Special requests
((and (listp element) ((and (listp element)
(eq (car element) 'MEMBERSHIPISREAD)) (memq (car element) '(MEMBERSHIPISREAD ALL-CONF-TEXTS)))
(setq lyskom-membership-is-read t)) (if (eq (car element) 'MEMBERSHIPISREAD)
(setq lyskom-membership-is-read t)
;; Temporarily disabled
(let ((queue (lyskom-queue-create)))
(setcar prefetch-list queue)
(mapcar
(lambda (read-info)
(mapcar
(lambda (text-no)
(lyskom-prefetch-text-all text-no queue))
(text-list->texts (read-info->text-list read-info))))
(read-list->all-entries lyskom-to-do-list))
(lyskom-queue-enter queue 'FINISHED)))
;; This is an ugly hack. If this function returns a non-nil
;; value, lyskom-prefetch-continue will assume that a server
;; call was made and increase lyskom-pending-prefetch. But
;; no server call has been made, so we decrease
;; lyskom-pending-prefetch "in advance". The reason that
;; this sets result to t is that we want the loop in
;; lyskom-continue-prefetch to keep running, as there is no
;; server response that will wake the prefetch up in the
;; future.
;;(-- lyskom-pending-prefetch)
;;(setq result t)
)
(t (signal 'lyskom-internal-error (t (signal 'lyskom-internal-error
'(lyskom-prefetch-one-item ": unknown key")))) '(lyskom-prefetch-one-item ": unknown key"))))
(setq prefetch-list rest-list) (setq prefetch-list rest-list)
(if (not (or prefetch-list (if (not (or prefetch-list
(lyskom-stack-isempty list-stack))) (lyskom-stack-isempty list-stack)))
...@@ -411,7 +471,8 @@ Return t if an element was prefetched, otherwise return nil." ...@@ -411,7 +471,8 @@ Return t if an element was prefetched, otherwise return nil."
(lyskom-prefetch-handler))) (lyskom-prefetch-handler)))
((eq (car request) 'CONFSTATFORMAP) ((eq (car request) 'CONFSTATFORMAP)