On Sat, May 4, 2024 at 12:11 AM Eli Zaretskii wrote: > I have > no idea how VirtualBox converts Windows clipboard data into X > clipboard/selection data -- do you happen to know? The reason of this > problem is probably there. > Sorry I am unfamiliar with how VirtualBox implements this. I know they use something called guest addition to allow bi-directional clipboard sharing. > And finally, the values of the following variables are of interest: > > > #11 0x000055b069603f3e in print_error_message (data=, > data@entry=0x55b085976613, > > stream=stream@entry=0x30, context=, caller=caller@entry=0x7fe0) > at lisp.h:1172 > > obj = > > li = {tortoise = 0x55b0859765f3, max = 2, n = 0, q = 1} > > sep = 0x55b0696ad6a0 ", " > > errname = 0x11f40 > > errmsg = 0x55b06c78e6e4 > > file_error = 0x0 > > tail = 0x55b0859765e3 > > In this call-stack frame, what is the value of 'data'? It is a Lisp > object, so showing it should involve using the commands xtype, xcar, > and xcdr, and probably also xstring (which are defined in .gdbinit). I did as directed. Emacs soon crashed and here is the analysis: (gdb) bt full #0 raise (sig=) at ../sysdeps/unix/sysv/linux/raise.c:50 set = { __val = {18446744067266837247, 0 } } pid = tid = #1 0x0000564c4c3e5cf8 in terminate_due_to_signal (sig=11, backtrace_limit=40) at emacs.c:464 #2 0x0000564c4c4141b2 in handle_fatal_signal (sig=11) at sysdep.c:1783 #3 0x0000564c4c414187 in deliver_thread_signal (sig=11, handler=0x564c4c414198 ) at sysdep.c:1775 old_errno = 11 #4 0x0000564c4c4141ed in deliver_fatal_thread_signal (sig=11) at sysdep.c:1795 #5 0x0000564c4c41438b in handle_sigsegv (sig=11, siginfo=0x564c4cb3e230 , arg=0x564c4cb3e100 ) at sysdep.c:1888 fatal = false #6 0x00007f8907b26140 in () at /lib/x86_64-linux-gnu/libpthread.so.0 #7 SYMBOL_NAME (sym=XIL(0x564c55abc5a0)) at lisp.h:2336 #8 0x0000564c4c4e0ca5 in print_object (obj=XIL(0x564c55abc5a0), printcharfun=XIL(0x30), escapeflag=true) at print.c:2393 len = 140226424574408 i = 140729353894864 name = XIL(0x21974e0) size_byte = 94885739624928 p = 0x564c4c41f35a "H\213@ \bH\205\300t\fH\213E\330H\211\307\350\336\362\006" signedp = false confusing = false base_depth = 0 base_sp = 0 buf = "\020H\220SLV\000\000\020H\220SLV\000\000`\205\264LLV\000\000`\000\000\000\000\000\000\000`\000\000\000\000\000\000\000\000\374%\033\376\177\000\000ܖHLLV" #9 0x0000564c4c4dddb4 in print (obj=XIL(0x564c55abc5a0), printcharfun=XIL(0x30), escapeflag=true) at print.c:1301 #10 0x0000564c4c4dcc92 in Fprin1 (object=XIL(0x564c55abc5a0), printcharfun=XIL(0x30), overrides=XIL(0)) at print.c:776 count = { bytes = 224 } pc = { printcharfun = XIL(0x30), old_printcharfun = XIL(0x30), old_point = -1, start_point = -1, old_point_byte = -1, start_point_byte = -1, specpdl_count = { bytes = 224 } } #11 0x0000564c4c4dd82f in print_error_message (data=XIL(0x564c52d9c853), stream=XIL(0x30), context=0x7f89023daa83 "", caller=XIL(0x293cb518a578)) at print.c:1134 obj = XIL(0x564c55abc5a0) li = { tortoise = XIL(0x564c52d9c873), max = 2, n = 0, q = 1 } sep = 0x564c4c5c1c0c ", " errname = XIL(0x11f40) errmsg = XIL(0x564c520b0a84) file_error = XIL(0) tail = XIL(0x564c52d9c883) #12 0x0000564c4c3ed1a9 in Fcommand_error_default_function (data=XIL(0x564c52d9c853), context=XIL(0x7f8901be9284), signal=XIL(0x293cb518a578)) at keyboard.c:1070 sf = 0x564c4ec8f6c8 conditions = XIL(0x7f89022845e3) is_minibuffer_quit = 0 #13 0x0000564c4c4b09a7 in funcall_subr (subr=0x564c4cabd2e0 , numargs=3, args=0x7f89014b1050) at eval.c:3042 argbuf = {XIL(0x564c4cb48500), XIL(0), XIL(0), XIL(0x7ffe1b25ffa0), XIL(0x564c4c4ffe4b), XIL(0x4cabd2e5), XIL(0x7ffe1b25ffc0), XIL(0x564c4c500741)} a = 0x7f89014b1050 fun = XIL(0x7ffe1b25ffe0) #14 0x0000564c4c50176b in exec_byte_code (fun=XIL(0x7f890204f18d), args_template=771, nargs=3, args=0x7ffe1b260640) at bytecode.c:809 call_nargs = 3 call_fun = XIL(0x564c4cabd2e5) count1 = { bytes = 192 } template = XIL(0x21b2600a0) val = XIL(0) call_args = 0x7f89014b1050 original_fun = XIL(0x293cb5507120) bytecode = make_fixnum(1393703692) op = 3 type = (unknown: 0x2398d60) targets = {0x564c4c504e7e , 0x564c4c504ea3 , 0x564c4c504ea5 , 0x564c4c504ea7 , 0x564c4c504ea9 , 0x564c4c504ea9 , 0x564c4c504f0e , 0x564c4c504f82 , 0x564c4c500f00 , 0x564c4c500f02 , 0x564c4c500f04 , 0x564c4c500f06 , 0x564c4c500f08 , 0x564c4c500f08 , 0x564c4c500f0e , 0x564c4c500ecf , 0x564c4c50128d , 0x564c4c50128f , 0x564c4c501291 , 0x564c4c501293 , 0x564c4c501295 , 0x564c4c501295 , 0x564c4c5012ca , 0x564c4c50129b , 0x564c4c501480 , 0x564c4c501482 , 0x564c4c501484 , 0x564c4c501486 , 0x564c4c501488 , 0x564c4c501488 , 0x564c4c50143a , 0x564c4c501451 , 0x564c4c501535 , 0x564c4c501537 , 0x564c4c501539 , 0x564c4c50153b , 0x564c4c50153d , 0x564c4c50153d , 0x564c4c5014ef , 0x564c4c501506 , 0x564c4c501890 , 0x564c4c501892 , 0x564c4c501894 , 0x564c4c501896 , 0x564c4c501898 , 0x564c4c501898 , 0x564c4c50184a , 0x564c4c501861 , 0x564c4c5020e0 , 0x564c4c501f36 , 0x564c4c501f2d , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c502325 , 0x564c4c50240f , 0x564c4c502471 , 0x564c4c5024d1 , 0x564c4c502533 , 0x564c4c501113 , 0x564c4c501195 , 0x564c4c5025ac , 0x564c4c501084 , 0x564c4c5011fd , 0x564c4c502614 , 0x564c4c50267c , 0x564c4c5026c4 , 0x564c4c50272c , 0x564c4c502792 , 0x564c4c502878 , 0x564c4c5028c0 , 0x564c4c502a01 , 0x564c4c502b6d , 0x564c4c502bb5 , 0x564c4c502bfd , 0x564c4c502c65 , 0x564c4c502ccd , 0x564c4c502d35 , 0x564c4c502dba , 0x564c4c502e09 , 0x564c4c502e58 , 0x564c4c502f1f , 0x564c4c502fc1 , 0x564c4c503063 , 0x564c4c503132 , 0x564c4c503214 , 0x564c4c5032f6 , 0x564c4c5033d8 , 0x564c4c5034ba , 0x564c4c5035ec , 0x564c4c50368f , 0x564c4c5037bb , 0x564c4c503881 , 0x564c4c503947 , 0x564c4c503ccb , 0x564c4c501dad , 0x564c4c503d26 , 0x564c4c503d6e , 0x564c4c503e30 , 0x564c4c503e8b , 0x564c4c503ee6 , 0x564c4c503f2e , 0x564c4c503f71 , 0x564c4c503fb4 , 0x564c4c503fff , 0x564c4c504e7e , 0x564c4c504057 , 0x564c4c50409a , 0x564c4c5040dd , 0x564c4c504120 , 0x564c4c504163 , 0x564c4c5041a6 , 0x564c4c501dad , 0x564c4c504e7e , 0x564c4c5041ee , 0x564c4c50423e , 0x564c4c504286 , 0x564c4c5042ce , 0x564c4c504336 , 0x564c4c50439e , 0x564c4c5043e6 , 0x564c4c50442e , 0x564c4c504496 , 0x564c4c5044fe , 0x564c4c504566 , 0x564c4c5045a9 , 0x564c4c504e7e , 0x564c4c501cf7 , 0x564c4c5018fe , 0x564c4c500ff2 , 0x564c4c5019a3 , 0x564c4c501a27 , 0x564c4c501aa8 , 0x564c4c501b29 , 0x564c4c501cc0 , 0x564c4c5013e7 , 0x564c4c501d76 , 0x564c4c501de4 , 0x564c4c501e75 , 0x564c4c501ebe , 0x564c4c50212c , 0x564c4c5021a9 , 0x564c4c50222e , 0x564c4c502294 , 0x564c4c504e7e , 0x564c4c5045f1 , 0x564c4c504676 , 0x564c4c5046be , 0x564c4c504706 , 0x564c4c50474e , 0x564c4c504796 , 0x564c4c5047fe , 0x564c4c504866 , 0x564c4c5048ce , 0x564c4c504936 , 0x564c4c504a47 , 0x564c4c504aaf , 0x564c4c504b17 , 0x564c4c504b5f , 0x564c4c504c1d , 0x564c4c504cdb , 0x564c4c504d23 , 0x564c4c504d6b , 0x564c4c503a85 , 0x564c4c503bd1 , 0x564c4c504dba , 0x564c4c504e1c , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c502800 , 0x564c4c502ea7 , 0x564c4c503db8 , 0x564c4c505011 , 0x564c4c505086 , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c505118 , 0x564c4c50519f , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c504e7e , 0x564c4c5052f7 } quitcounter = 1 '\001' bc = 0x564c4cab2410 top = 0x7f89014b1048 pc = 0x7f89024b5001 "\210\002:\205:" bytestr = XIL(0x7f890204f674) vector = XIL(0x7f890204f1cd) maxdepth = make_fixnum(11) const_length = 7 bytestr_length = 59 vectorp = 0x7f890204f1d0 max_stack = 11 frame_base = 0x7f89014b1030 fp = 0x7f89014b1088 bytestr_data = 0x7f89024b4ffc "\300\003\003\003#\210\002:\205:" rest = false mandatory = 3 nonrest = 3 pushedargs = 3 result = XIL(0) #15 0x0000564c4c4b0c6d in fetch_and_exec_byte_code (fun=XIL(0x7f890204f18d), args_template=771, nargs=3, args=0x7ffe1b260628) at eval.c:3085 #16 0x0000564c4c4b0fe1 in funcall_lambda (fun=XIL(0x7f890204f18d), nargs=3, arg_vector=0x7ffe1b260628) at eval.c:3157 val = XIL(0x7ffe1b260560) syms_left = make_fixnum(771) next = XIL(0) lexenv = XIL(0x1e0204f158) count = { bytes = 192 } i = 45340716723288 optional = false rest = false previous_rest = false #17 0x0000564c4c4b050d in funcall_general (fun=XIL(0x7f890204f18d), numargs=3, args=0x7ffe1b260628) at eval.c:2949 original_fun = XIL(0x293cb5506c58) #18 0x0000564c4c4b078e in Ffuncall (nargs=4, args=0x7ffe1b260620) at eval.c:2999 count = { bytes = 160 } val = XIL(0x7ffe1b2605f0) #19 0x0000564c4c3eaf38 in call3 (fn=XIL(0x293cb5506c58), arg1=XIL(0x564c52d9c853), arg2=XIL(0x7f8901be9284), arg3=XIL(0x293cb518a578)) at lisp.h:3262 #20 0x0000564c4c3ecf9f in cmd_error_internal (data=XIL(0x564c52d9c853), context=0x7ffe1b2606d0 "") at keyboard.c:1013 #21 0x0000564c4c3ece84 in cmd_error (data=XIL(0x564c52d9c853)) at keyboard.c:981 old_level = XIL(0) old_length = XIL(0) count = { bytes = 96 } conditions = XIL(0x7f89022845e3) macroerror = "\000\a&\033\376\177\000\000L\316JLLV\000\000\367\213JL\001\000\000\000`\000\000\000\000\000\000\000\060\a&\033\376\177\000\000\324S\316RLV\000\000\000" #22 0x0000564c4c4ac9ee in internal_condition_case (bfun=0x564c4c3ed64e , handlers=XIL(0x90), hfun=0x564c4c3ecc8c ) at eval.c:1470 val = XIL(0x564c52d9c853) c = 0x564c4e5443e0 #23 0x0000564c4c3ed316 in command_loop_2 (handlers=XIL(0x90)) at keyboard.c:1133 val = make_fixnum(0) #24 0x0000564c4c4ac0be in internal_catch (tag=XIL(0x10080), func=0x564c4c3ed2ef , arg=XIL(0x90)) at eval.c:1197 val = XIL(0x7ffe1b260810) c = 0x564c4e5424c0 #25 0x0000564c4c3ed2ab in command_loop () at keyboard.c:1111 #26 0x0000564c4c3ec837 in recursive_edit_1 () at keyboard.c:720 count = { bytes = 32 } val = make_fixnum(23721424373675) #27 0x0000564c4c3ec9e0 in Frecursive_edit () at keyboard.c:803 count = { bytes = 0 } buffer = XIL(0) #28 0x0000564c4c3e8dbf in main (argc=1, argv=0x7ffe1b260af8) at emacs.c:2521 stack_bottom_variable = 0x564c4e4a3f20 no_loadup = false junk = 0x0 dname_arg = 0x0 ch_to_dir = 0x0 original_pwd = 0x0 dump_mode = 0x0 skip_args = 0 temacs = 0x0 attempt_load_pdump = true only_version = false rlim = { rlim_cur = 10022912, rlim_max = 18446744073709551615 } lc_all = 0x0 sockfd = -1 module_assertions = false You can't do that without a process to debug. (gdb) frame 11 #11 0x0000564c4c4dd82f in print_error_message (data=XIL(0x564c52d9c853), stream=XIL(0x30), context=0x7f89023daa83 "", caller=XIL(0x293cb518a578)) at print.c:1134 1134 Fprin1 (obj, stream, Qnil); (gdb) info locals obj = XIL(0x564c55abc5a0) li = { tortoise = XIL(0x564c52d9c873), max = 2, n = 0, q = 1 } sep = 0x564c4c5c1c0c ", " errname = XIL(0x11f40) errmsg = XIL(0x564c520b0a84) file_error = XIL(0) tail = XIL(0x564c52d9c883) (gdb) print data $1 = XIL(0x564c52d9c853) (gdb) xtype data Lisp_Cons (gdb) xcar data $2 = 0x11f40 (gdb) xcdr data $3 = 0x0 (gdb) xstring data $4 = (struct Lisp_String *) 0x0 "DEAD" (gdb) print obj $31 = XIL(0x564c55abc5a0) (gdb) xtype obj Lisp_Symbol (gdb) xcar obj $32 = 0x0 (gdb) xcdr obj $33 = 0x0 (gdb) xstring obj $34 = (struct Lisp_String *) 0x0 "DEAD" (gdb) print li $35 = { tortoise = XIL(0x564c52d9c873), max = 2, n = 0, q = 1 } (gdb) xtype li Invalid cast. (gdb) xcar li Invalid cast. (gdb) xcdr li Invalid cast. (gdb) xstring li Invalid cast. (gdb) print sep $36 = 0x564c4c5c1c0c ", " (gdb) xtype sep Lisp_String (gdb) xcar sep $37 = 0x0 (gdb) xcdr sep $38 = 0x0 (gdb) xstring sep $39 = (struct Lisp_String *) 0x0 "DEAD" (gdb) print errname $40 = XIL(0x11f40) (gdb) xtype errname Lisp_Symbol (gdb) xcar errname $41 = 0x0 (gdb) xcdr errname $42 = 0x0 (gdb) xstring errname $43 = (struct Lisp_String *) 0x0 "DEAD" (gdb) print errmsg $44 = XIL(0x564c520b0a84) (gdb) xtype errmsg Lisp_String (gdb) xcar errmsg $45 = 0x0 (gdb) xcdr errmsg $46 = 0x0 (gdb) xstring errmsg $47 = (struct Lisp_String *) 0x0 "DEAD" (gdb) print file No symbol "file" in current context. (gdb) xtype file Lisp_Symbol (gdb) xcar file $48 = 0x0 (gdb) xcdr file $49 = 0x0 (gdb) xstring file $50 = (struct Lisp_String *) 0x0 "DEAD" (gdb) print tail $51 = XIL(0x564c52d9c883) (gdb) xtype tail Lisp_Cons (gdb) xcar tail $52 = 0x564c55abc5a0 (gdb) xcdr tail $53 = 0x0 (gdb) xstring tail $54 = (struct Lisp_String *) 0x0 "DEAD" > Also, if you know what was the text copied from the other application, > please show that text. > It seems to crash randomly. I will try to note down what I copied next time it crashes.