File: int-conversion.patch

package info (click to toggle)
dico 2.12-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 21,300 kB
  • sloc: ansic: 94,671; sh: 52,520; lex: 4,023; tcl: 1,439; yacc: 1,439; makefile: 1,387; python: 1,310; perl: 1,200; lisp: 489; awk: 157; pascal: 127; javascript: 71; cpp: 50; fortran: 28; asm: 21; sed: 16; xml: 8
file content (27 lines) | stat: -rw-r--r-- 1,002 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Author: Andreas Beckmann <anbe@debian.org>
Description: fix building with -Werror=int-conversion
Bug: https://puszcza.gnu.org.ua/bugs/index.php?646
Forwarded: https://puszcza.gnu.org.ua/bugs/download.php?file_id=544

Index: dico/modules/python/python.c
===================================================================
--- dico.orig/modules/python/python.c	2025-01-02 14:47:45.419666326 +0100
+++ dico/modules/python/python.c	2025-01-02 14:47:45.419666326 +0100
@@ -100,7 +100,7 @@
 }
 
 static PyTypeObject PySelectionKeyType = {
-    PyObject_HEAD_INIT(&PyType_Type)
+    PyVarObject_HEAD_INIT(&PyType_Type, 0)
     .tp_name = "DicoSelectionKey",
     .tp_basicsize = sizeof (PySelectionKey),
     .tp_dealloc = _PySelectionKey_dealloc,
@@ -185,7 +185,7 @@
 }
 
 static PyTypeObject PyStrategyType = {
-    PyObject_HEAD_INIT(&PyType_Type)
+    PyVarObject_HEAD_INIT(&PyType_Type, 0)
     .tp_name = "DicoStrategy",
     .tp_basicsize = sizeof (PyStrategy),
     .tp_dealloc = _PyStrategy_dealloc,