Skip to content

Commit

Permalink
sagemathgh-38628: Fix hypellfrob.pyx calling Python inside sig_on
Browse files Browse the repository at this point in the history
set_ntl_matrix_modn_dense uses isinstance so there is a chance for
Python garbage collection to run. Presumably you get the

    SystemError: calling remove_from_pari_stack() inside sig_on()

if that happens.

Fixes sagemath#33304

URL: sagemath#38628
Reported by: Volker Braun
Reviewer(s): Matthias Köppe
  • Loading branch information
Release Manager committed Sep 8, 2024
2 parents 25f80f6 + 4fcf282 commit 9c1c84a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions build/pkgs/configure/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
tarball=configure-VERSION.tar.gz
sha1=0f6355fc136bb6619585863b9e4bc954cc6e0e3d
sha256=5b618581d51997afa78b5e6647584f7ef4e6d5844823dd44e607f2accd7abba5
sha1=82220a1037f78e225e25413d84c08e1aee28026b
sha256=74958c6adc83549f977ceae8086ae45eacc7f6ff66ca4fa0a5023549d3533307
2 changes: 1 addition & 1 deletion build/pkgs/configure/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
b9cb7bc2559cde857d84d77f0b37a3616ce1eb6c
5d8f2baef836d43fd7b3250585e9a250be4a05d7
2 changes: 2 additions & 0 deletions src/sage/schemes/hyperelliptic_curves/hypellfrob.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,10 @@ def interval_products(M0, M1, target):
cdef long dim = M0.nrows()
sig_on()
c.restore_c()
sig_off()
set_ntl_matrix_modn_dense(mm0, c, M0)
set_ntl_matrix_modn_dense(mm1, c, M1)
sig_on()
for t in target:
targ.push_back(ntl_ZZ(t).x)
numintervals = len(target)/2
Expand Down

0 comments on commit 9c1c84a

Please sign in to comment.