From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/34562 Path: main.gmane.org!not-for-mail From: Simon Josefsson Newsgroups: gmane.emacs.gnus.general Subject: Re: nnimap hangs on connect plus Garbage: Date: 06 Feb 2001 00:22:00 +0100 Sender: owner-ding@hpc.uh.edu Message-ID: References: NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1035170468 31095 80.91.224.250 (21 Oct 2002 03:21:08 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 21 Oct 2002 03:21:08 +0000 (UTC) Cc: ding@gnus.org Return-Path: Original-Received: from karazm.math.uh.edu (karazm.math.uh.edu [129.7.128.1]) by mailhost.sclp.com (Postfix) with ESMTP id 14A6ED049D for ; Mon, 5 Feb 2001 18:27:13 -0500 (EST) Original-Received: from sina.hpc.uh.edu (lists@Sina.HPC.UH.EDU [129.7.3.5]) by karazm.math.uh.edu (8.9.3/8.9.3) with ESMTP id RAC05208; Mon, 5 Feb 2001 17:22:56 -0600 (CST) Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Mon, 05 Feb 2001 17:21:52 -0600 (CST) Original-Received: from mailhost.sclp.com (postfix@66-209.196.61.interliant.com [209.196.61.66] (may be forged)) by sina.hpc.uh.edu (8.9.3/8.9.3) with ESMTP id RAA27947 for ; Mon, 5 Feb 2001 17:21:38 -0600 (CST) Original-Received: from dolk.extundo.com (dolk.extundo.com [195.42.214.242]) by mailhost.sclp.com (Postfix) with ESMTP id C7CD1D049D for ; Mon, 5 Feb 2001 18:22:03 -0500 (EST) Original-Received: from barbar.josefsson.org (slipsten.extundo.com [195.42.214.241]) by dolk.extundo.com (8.11.2/8.11.2) with ESMTP id f15NM2u19036; Tue, 6 Feb 2001 00:22:02 +0100 Original-To: Mats Lidell In-Reply-To: (Mats Lidell's message of "05 Feb 2001 23:10:00 +0100") User-Agent: Gnus/5.090001 (Oort Gnus v0.01) Emacs/21.0.97 Precedence: list X-Majordomo: 1.94.jlt7 Original-Lines: 42 Xref: main.gmane.org gmane.emacs.gnus.general:34562 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:34562 Mats Lidell writes: > Simon> Also, my experience is that if I don't use the workaround, > Simon> Emacs locks up completely (any number of C-g doesn't help). I > Simon> think it's a race condition in Emacs process I/O. I'm hoping > Simon> that some emacs I/O guru discover the same problem and fix > Simon> it. :) > > Hmm... So what you are saying really is that this might be hard for us > fix. Yes. Now that I try it, I'm not even able to reproduce it. > Simon> Your workaround probably causes enough delay after opening the > Simon> connection until something is read/written to make things work, > Simon> just as my workaround. Perhaps imap.el could `sit-for' a > Simon> second or so after opening external processes. Hm. > > I'd definitely would prefere that. Simple enough even for me to > experiment with. ;-) Does the following have any effect? --- imap.el.~6.3.~ Wed Dec 20 18:14:16 2000 +++ imap.el Tue Feb 6 00:20:04 2001 @@ -857,13 +857,16 @@ imap-current-message nil imap-state 'initial imap-process (condition-case () + (sit-for 1) (funcall (nth 2 (assq imap-stream imap-stream-alist)) "imap" buffer imap-server imap-port) + (sit-for 1) ((error quit) nil))) (when imap-process (set-process-filter imap-process 'imap-arrival-filter) (set-process-sentinel imap-process 'imap-sentinel) + (sit-for 1) (while (and (eq imap-state 'initial) (memq (process-status imap-process) '(open run))) (message "Waiting for response from %s..." imap-server)