[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Emacs-diffs] trunk r116230: Fix bug #16558 with w32-shell-execute o

From: Stefan-W. Hahn
Subject: Re: [Emacs-diffs] trunk r116230: Fix bug #16558 with w32-shell-execute on remote file names.
Date: Sun, 2 Feb 2014 08:45:20 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

Mail von Stefan Monnier, Sat, 01 Feb 2014 at 19:44:54 -0500:

Good Morning,

> >> > +        * w32fns.c (Fw32_shell_execute): Don't call file-exists-p for
> >> > +        DOCUMENT that is a "remote" file name, i.e. a file-handler 
> >> > exists
> >> > +        for it.  (Bug#16558)
> >> That means we don't call Ffile_exists_p for .gz files :-(
> >> It seems arbitrary.
> > What do you suggest? bind handlers-alist to nil?
> Could you describe the problem we're trying to solve?

because I sent the bug report, I try to summarize.  Because I'm not familar
with the internals of emacs, I just use it, please throw away my thoughts if
they are nonsens.

I think the main problems are:
- to define what Fw32_shell_execute has to do before calling Shellexecute
  and what not.
- to distinct between real files and virtual objects.

There are handlers for both types defined by file-name-handler-alist
and if ShellExecute is called then windows itself also has handlers
defined be registry (HKEY_CLASSES_ROOT\CLSID\{object_clsid}\Shell\verb).

So, if calling a file-handler function inside of Fw32_shell_execute then
file-name-handler-alist transforms the calls (this was my problem with the
call to file-exists-p on an "https://url"; because this was translated to a
file download, which is not intended, because I wanted just to start the
browser and in my case the url was in RESTAPI syntax too).

Afterwards windows interprets the filename (or objectname) by checking the
registry. So it knows how to handle things (i.e. virtual objects: http://url, 
outlook:00000000EFABE93C5C7E4947B0D4C936C001637FE4782400 (calls outlook), etc.).

For me, if calling w32-shell-execute, the intention is to give the control
of what to do with the object to windows.

Kind regards,

Stefan-W. Hahn                          It is easy to make things.
                                        It is hard to make things simple.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]