diff --git a/SPKG.txt b/SPKG.txt
a
|
b
|
|
80 | 80 | |
81 | 81 | == Changelog == |
82 | 82 | |
| 83 | === pari-2.5.0.p3 (Jeroen Demeyer, 20 December 2011) === |
| 84 | * Ticket #12158: add reorder_init_opts.patch such that warnings |
| 85 | during pari_init_opts() do not cause segfaults. |
| 86 | |
83 | 87 | === pari-2.5.0.p2 (Jeroen Demeyer, 26 July 2011) === |
84 | 88 | * Ticket #11130: update to PARI stable version 2.5.0, which is |
85 | 89 | equal to svn version 13228. |
diff --git a/patches/README.txt b/patches/README.txt
a
|
b
|
|
43 | 43 | *and* MPIR. To disable the use, add "-DPARI_DONT_USE_GMP_INTERNALS" |
44 | 44 | to CFLAGS. This is a trivial patch to mp.c only; see also the comment |
45 | 45 | there.): |
| 46 | * reorder_init_opts.patch: call pari_init_defaults() *before* calling |
| 47 | gp_expand_path(), such that warnings during gp_expand_path() do not |
| 48 | cause a dereference of the NULL pointer pariErr. |
| 49 | Reported upstream at |
| 50 | http://pari.math.u-bordeaux.fr/cgi-bin/bugreport.cgi?bug=1264 |
46 | 51 | |
47 | 52 | Upstream patches included (file name refers to the ticket in PARI's bug |
48 | 53 | tracking system, see |
diff --git a/patches/reorder_init_opts.patch b/patches/reorder_init_opts.patch
new file mode 100644
-
|
+
|
|
| 1 | Index: src/language/init.c |
| 2 | =================================================================== |
| 3 | --- src/language/init.c (revision 13228) |
| 4 | +++ src/language/init.c (working copy) |
| 5 | @@ -731,8 +731,8 @@ |
| 6 | pari_stackcheck_init(&u); |
| 7 | if ((init_opts&INIT_DFTm)) { |
| 8 | GP_DATA = default_gp_data(); |
| 9 | + pari_init_defaults(); |
| 10 | gp_expand_path(GP_DATA->path); |
| 11 | - pari_init_defaults(); |
| 12 | } |
| 13 | |
| 14 | if ((init_opts&INIT_SIGm)) pari_sig_init(pari_sighandler); |