From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Lennart Borgman (gmail)" Newsgroups: gmane.emacs.bugs Subject: bug#549: emacsclient or emacsclientw not waiting in Windows Date: Tue, 15 Jul 2008 09:37:32 +0200 Message-ID: <487C53BC.4030807@gmail.com> References: <5f9de3c40807142340o7954c128i3130aedcd98de3d0@mail.gmail.com> Reply-To: "Lennart Borgman \(gmail\)" , 549@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1216108062 22131 80.91.229.12 (15 Jul 2008 07:47:42 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 15 Jul 2008 07:47:42 +0000 (UTC) Cc: bug-gnu-emacs@gnu.org, 549@emacsbugs.donarmstrong.com To: Vesa Suontama Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Jul 15 09:48:30 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KIfGs-0004tU-9a for geb-bug-gnu-emacs@m.gmane.org; Tue, 15 Jul 2008 09:48:26 +0200 Original-Received: from localhost ([127.0.0.1]:47797 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KIfG0-00065T-2K for geb-bug-gnu-emacs@m.gmane.org; Tue, 15 Jul 2008 03:47:32 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KIfFu-00065B-Kr for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:47:26 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KIfFu-00064t-0L for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:47:26 -0400 Original-Received: from [199.232.76.173] (port=54795 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KIfFt-00064n-Rq for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:47:25 -0400 Original-Received: from mx20.gnu.org ([199.232.41.8]:45646) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KIfFt-0000br-BS for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:47:25 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KIfFs-0004y9-34 for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:47:24 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m6F7lG8x024155; Tue, 15 Jul 2008 00:47:16 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m6F7j396023041; Tue, 15 Jul 2008 00:45:03 -0700 X-Loop: don@donarmstrong.com Resent-From: "Lennart Borgman (gmail)" Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs , don@donarmstrong.com Resent-Date: Tue, 15 Jul 2008 07:45:03 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 549 X-Emacs-PR-Package: emacs,w32 X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.121610746821808 (code B ref -1); Tue, 15 Jul 2008 07:45:03 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 15 Jul 2008 07:37:48 +0000 Original-Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m6F7bihL021802 for ; Tue, 15 Jul 2008 00:37:46 -0700 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KIf6V-0002Xp-Oi for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:37:43 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KIf6U-0002XG-Mr for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:37:42 -0400 Original-Received: from [199.232.76.173] (port=52598 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KIf6U-0002XC-Hn for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:37:42 -0400 Original-Received: from mx20.gnu.org ([199.232.41.8]:44991) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KIf6U-0007vP-14 for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:37:42 -0400 Original-Received: from ch-smtp01.sth.basefarm.net ([80.76.149.212]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KIf6T-0003lO-2g for bug-gnu-emacs@gnu.org; Tue, 15 Jul 2008 03:37:41 -0400 Original-Received: from c83-254-145-59.bredband.comhem.se ([83.254.145.59]:62701 helo=[127.0.0.1]) by ch-smtp01.sth.basefarm.net with esmtp (Exim 4.68) (envelope-from ) id 1KIf6O-0001IS-3e; Tue, 15 Jul 2008 09:37:39 +0200 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666 In-Reply-To: <5f9de3c40807142340o7954c128i3130aedcd98de3d0@mail.gmail.com> X-Antivirus: avast! (VPS 080712-0, 2008-07-12), Outbound message X-Antivirus-Status: Clean X-Originating-IP: 83.254.145.59 X-Scan-Result: No virus found in message 1KIf6O-0001IS-3e. X-Scan-Signature: ch-smtp01.sth.basefarm.net 1KIf6O-0001IS-3e f505009c40d1042ea0e5cd4bb77608bf X-detected-kernel: by mx20.gnu.org: Linux 2.6? (barebone, rare!) X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-CrossAssassin-Score: 2 X-MIME-Autoconverted: from 8bit to quoted-printable by rzlab.ucr.edu id m6F7lG8x024155 X-detected-kernel: by mx20.gnu.org: Linux 2.6 (newer, 3) X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) Resent-Date: Tue, 15 Jul 2008 03:47:26 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:18725 Archived-At: Vesa Suontama wrote: > Hi, >=20 > thanks for clarification. It seems now that I was not testing > emacsclient at all, since now when I test it it works. I am very sorry > for misleading bug report. >=20 > I was not aware that emacsclientw does not wait, and thought that the > only difference there is that emacsclientw is compiled as windows > binary, which does not create (or use) a console. Just to not confuse any readers: emacsclientw.exe does wait. You can see it in Window Task Manager.=20 However the console window does not wait for emacsclientw.exe since it=20 is not a console app. > This is quite sorry state of affairs, that windows needs to have > two emacsclient versions. (At least when the difference is not that > well or at all explained IMHO). You can always use emacsclient.exe if you want to. The drawback is that=20 you will see an extra console window for each invocation of it. > It would be interesting to know why you just cannot have one > emacsclient for windows? Would it be too complex to go around the > issue of having two emacsclient versions the same way as MS does (Yes, > I know this is insane, but look many MS utilities e.g. devenv). >=20 > It works like this: have emacsclient.com and emacsclient.exe, where > new emacsclient.exe is the old emacsclientw.exe, and emacsclient.com > is just a wrapper that calls the emacsclient and waits for it to > finish (e.g. by using a named event, which emacsclient.com waits). Please try to write some code for this so we can test it. > Console programs use .com version by default (when only "emacsclient" > is called), and win32 uses .exe. We cannot directly rename > emacsclient.exe to emacsclient.com because there is a restriction that > com files can only be less than 64 kb. >=20 > The other way around could be to use "AttachConsole" etc. from > emacsclientw (and rename it to emacsclient), but all this is just guess= ing > as I do not know the real reason for emacsclientw. If you know how to do this then please try writing some code for that so=20 we can test that. This may be a better solution than the one above. > I would like to hear from you, but understand if you are too busy. >=20 > Thanks for your help anyway. >=20 > BR, >=20 > Vesa >=20 >> -----Original Message----- >> From: Lennart Borgman (gmail) [mailto:lennart.borgman@gmail.com] >> Sent: 14. hein=E4kuuta 2008 18:39 >> To: Vesa Suontama; 549@emacsbugs.donarmstrong.com >> Cc: bug-gnu-emacs@gnu.org >> Subject: Re: bug#549: emacsclient or emacsclientw not waiting in >> Windows >> >> Vesa Suontama wrote: >>> Hi, >>> >>> I have a Windows Vista SP1, and when using emacsclient or >> emacsclientw, >>> they always return immediately with return value 1, and do not wait >>> making it useless as EDITOR for command line utilities which should >> wait. >>> I use the emacsclient from cmd.exe and not from cygwin. I also >> started >>> emacs with =96q, and started server manually after that, so no startu= p >>> file should be causing this. >>> >>> Is this a known issue? >>> >>> Otherwise I love emacs :) >>> >>> Vesa >>> >>> In GNU Emacs 22.2.1 (i386-mingw-nt6.0.6001) >>> >>> of 2008-03-26 on RELEASE >>> >>> Windowing system distributor `Microsoft Corp.', version 6.0.6001 >> >> I do not have Emacs 22 here. However I just tested with CVS Emacs 23, >> both unpatched and the patched version that comes with Emacs+EmacsW32. >> I >> saw no problem, both emacsclient and emacsclientw waited as expected. >> >> Some notes: >> >> - Please use -Q (uppercase), not -q (lowercase). -q will still run >> site-start.el >> >> - If you test from a console window (running cmd.exe) then please note >> that emacsclientw can not make cmd.exe wait for it. I can't remember >> the >> technical terms for it but w here stands for "window, GUI". Program >> linked as GUI applications do not use a console window (by default). >> They can not write to a console and if started from a console the >> console will not wait for them. >=20