From: Eli Zaretskii <eliz@gnu.org>
To: Chunyu Wang <cymacs@gmail.com>
Cc: 6126@debbugs.gnu.org
Subject: bug#6126: 24.0.50; Segmentation fault when w32-shell-execute try to open an unassociated file
Date: Fri, 07 May 2010 18:12:07 +0300 [thread overview]
Message-ID: <837hnfkapk.fsf@gnu.org> (raw)
In-Reply-To: <h2nd4d843eb1005070721za7e5d22evea176fedb7c5dc62@mail.gmail.com>
> From: Chunyu Wang <cymacs@gmail.com>
> Date: Fri, 7 May 2010 22:21:39 +0800
> Cc: 6126@debbugs.gnu.org
>
> 2010/5/7 Eli Zaretskii <eliz@gnu.org>:
> > Does this problem happen in an unoptimized build as well? If so,
> > could you please find out what is the table it is using (the `tbl'
> > variable in frame #0), and also what is `val' (by using the xtype
> > command and a command to show the Lisp type printed by xtype, probably
> > xchartable)?
> Crashed as before for an unoptimized build one. The following is my tracing and
> information about `tbl' and `val'. If need some other thing, just tell
> me how to get it.
Can you try the following patch, and see if it resolves the problem?
=== modified file 'src/w32fns.c'
--- src/w32fns.c 2010-03-31 09:08:40 +0000
+++ src/w32fns.c 2010-05-07 15:07:43 +0000
@@ -47,6 +47,7 @@ along with GNU Emacs. If not, see <http
#include "systime.h"
#include "termhooks.h"
#include "w32heap.h"
+#include "w32.h"
#include "bitmaps/gray.xbm"
@@ -6333,6 +6334,7 @@ an integer representing a ShowWindow fla
Lisp_Object operation, document, parameters, show_flag;
{
Lisp_Object current_dir;
+ char *errstr;
CHECK_STRING (document);
@@ -6353,7 +6355,17 @@ an integer representing a ShowWindow fla
XINT (show_flag) : SW_SHOWDEFAULT))
> 32)
return Qt;
- error ("ShellExecute failed: %s", w32_strerror (0));
+ errstr = w32_strerror (0);
+ /* The error string might be encoded in the locale's encoding. */
+ if (!NILP (Vlocale_coding_system))
+ {
+ Lisp_Object decoded =
+ code_convert_string_norecord (make_unibyte_string (errstr,
+ strlen (errstr)),
+ Vlocale_coding_system, 0);
+ errstr = (char *)SDATA (decoded);
+ }
+ error ("ShellExecute failed: %s", errstr);
}
/* Lookup virtual keycode from string representing the name of a
next prev parent reply other threads:[~2010-05-07 15:12 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-06 16:08 bug#6126: 24.0.50; Segmentation fault when w32-shell-execute try to open an unassociated file Chunyu Wang
2010-05-07 0:00 ` Lennart Borgman
2010-05-07 1:52 ` Chunyu Wang
2010-05-07 9:27 ` Eli Zaretskii
2010-05-07 10:52 ` Lennart Borgman
2010-05-07 9:03 ` Eli Zaretskii
2010-05-07 12:17 ` Chunyu Wang
2010-05-07 14:21 ` Chunyu Wang
2010-05-07 15:12 ` Eli Zaretskii [this message]
2010-05-07 16:29 ` Chunyu Wang
2010-05-07 17:16 ` Eli Zaretskii
2010-05-07 20:52 ` Lennart Borgman
2010-05-08 7:15 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=837hnfkapk.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=6126@debbugs.gnu.org \
--cc=cymacs@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.