Closed gnusupport closed 5 years ago
Now I find that problem appears even with "SELECT 1".
There is always same bug coming up. Do you have idea maybe?
Thanks for the report, I can reproduce it with the latest emacs master. I don't see anything suspicious in emacs' change log wrt. the module interface at first glance. Running git-bisect on emacs now to find out more.
Thank you much.
Latest commit that works is a1c53d4294550380de76d6a6c4e29e9e8f6f9133 Date: Tue Apr 16 14:33:24 2019 -0700
One before that one that worked is e40f39bec34feeec893fb66625f19cc4663cd217 Date: Sun Apr 14 09:27:50 2019 -0600
somewhere in the middle from April 16th to near the present time, Emacs is segfault on loading of the module.
I am trying ti find commit closer to the present time that works well.
git-bisect yielded the following, which includes some changes to the module interface. Taking a closer look at them now.
09d746dad36e4780d379f975a84b1b076da78c50 is the first bad commit
commit 09d746dad36e4780d379f975a84b1b076da78c50
Author: Eli Zaretskii <eliz@gnu.org>
Date: Fri Mar 22 11:02:46 2019 +0300
Revert "Revert "Revert "Rely on conservative stack scanning to find "emacs_value"s"""
This reverts commit 093d3e78d21d3d6c718997368ef4b31f9884401c,
which reverted ee7ad83f20903208404a84b58b7a478b62924570,
which reverted 3eb93c07f7a60ac9ce8a16f10c3afd5a3a31243a.
:040000 040000 911b54468dc8d3889071ff44320a850edf47229d f252275a4e125c20402e7c686d73aeb6be476190 M src
:040000 040000 bd75dbaf17f1777bff74d16ad0998d7ab0d3534c a795cf9fb7e5ade1041a70e5190c7f9847912549 M test
bisect run success
From gnu-emacs-help mailing list, as suggested by Philipp Stephani, I did following if this can help, and it was done with the latest commit:
emacs --module-assertion
Emacs module assertion: Emacs value not found in 11 values of 1 environments
Fatal error 6: Aborted
Backtrace:
emacs[0x5039f2]
emacs[0x4176a5]
emacs[0x41788b]
emacs[0x418223]
emacs[0x58cb31]
emacs[0x58ef72]
/home/admin/Programming/git/emacs-libpq/pq.so(+0x14ed)[0x7fd9e35444ed]
Aborted
The issue is most likely that https://github.com/anse1/emacs-libpq/blob/master/pq.c#L325-L326 puts local references into static variables, which is not allowed, see https://phst.eu/emacs-modules#value-lifetime.
Philipp writes:
The issue is most likely that https://github.com/anse1/emacs-libpq/blob/master/pq.c#L325-L326 puts local references into static variables, which is not allowed, see https://phst.eu/emacs-modules#value-lifetime.
Thanks, after removing these static vars, the testsuite passes again with current emacs master at dbe81e16583.
717g301github: can you confirm the latest commit fixes the issue for you?
I confirm, it works well now again, just as it was. Thank you much for efforts. It means!
(["tlds_id" "integer" "nextval('tlds_tlds_id_seq'::regclass)" "" 1 #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "p" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "ID"] ["tlds_tld" "text" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "" 2 #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "x" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "TLD"] ["tlds_nic" "integer" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> 3 #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "p" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "NIC Company"] ["tlds_description" "text" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> 4 #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "x" #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug> "Description"] . #<EMACS BUG: INVALID DATATYPE (0x01) Save your buffers immediately and please report this bug>)