diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2024-11-23 15:59:19 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2024-11-23 15:59:19 (GMT) |
commit | 411f03130cf45194689bc344f19a3b77c33a31ae (patch) | |
tree | f047b62015eb37e30629398f9adcb977a5a6c6f6 /plugins/pychrysalide/glibext | |
parent | 80d779749adf228078b61f268bf952ba91a277f0 (diff) |
Restore more features for formats.
Diffstat (limited to 'plugins/pychrysalide/glibext')
-rw-r--r-- | plugins/pychrysalide/glibext/Makefile.am | 4 | ||||
-rw-r--r-- | plugins/pychrysalide/glibext/constants.c | 10 | ||||
-rw-r--r-- | plugins/pychrysalide/glibext/constants.h | 4 | ||||
-rw-r--r-- | plugins/pychrysalide/glibext/module.c | 4 | ||||
-rw-r--r-- | plugins/pychrysalide/glibext/portion.c | 195 | ||||
-rw-r--r-- | plugins/pychrysalide/glibext/portion.h | 12 |
6 files changed, 90 insertions, 139 deletions
diff --git a/plugins/pychrysalide/glibext/Makefile.am b/plugins/pychrysalide/glibext/Makefile.am index e9c3756..8b021bb 100644 --- a/plugins/pychrysalide/glibext/Makefile.am +++ b/plugins/pychrysalide/glibext/Makefile.am @@ -2,9 +2,7 @@ noinst_LTLIBRARIES = libpychrysaglibext.la # libpychrysaglibext_la_SOURCES = \ -# constants.h constants.c \ # binarycursor.h binarycursor.c \ -# binportion.h binportion.c \ # buffercache.h buffercache.c \ # bufferline.h bufferline.c \ # comparison.h comparison.c \ @@ -24,7 +22,9 @@ noinst_LTLIBRARIES = libpychrysaglibext.la # endif libpychrysaglibext_la_SOURCES = \ + constants.h constants.c \ module.h module.c \ + portion.h portion.c \ work.h work.c \ workqueue.h workqueue.c diff --git a/plugins/pychrysalide/glibext/constants.c b/plugins/pychrysalide/glibext/constants.c index 169ffa2..90ce8cd 100644 --- a/plugins/pychrysalide/glibext/constants.c +++ b/plugins/pychrysalide/glibext/constants.c @@ -25,16 +25,18 @@ #include "constants.h" +#include <glibext/portion.h> + +/* #include <i18n.h> #include <glibext/bufferline.h> #include <glibext/comparison.h> #include <glibext/configuration.h> #include <glibext/linesegment.h> -#include <glibext/gbinportion.h> #ifdef INCLUDE_GTK_SUPPORT # include <glibext/gloadedpanel.h> #endif - +*/ #include "../helpers.h" @@ -58,6 +60,7 @@ bool define_binary_portion_constants(PyTypeObject *type) PyObject *strdict; /* Groupe de chaînes constantes*/ PyObject *values; /* Groupe de valeurs à établir */ + /* result = create_string_constants_group_to_type(type, "BinaryPortionCode", "Selector names for the CSS rendering.", &strdict); @@ -69,6 +72,7 @@ bool define_binary_portion_constants(PyTypeObject *type) if (!result) goto exit; + */ values = PyDict_New(); @@ -150,6 +154,7 @@ int convert_to_portion_access_rights(PyObject *arg, void *dst) } +#if 0 /****************************************************************************** * * * Paramètres : type = type dont le dictionnaire est à compléter. * @@ -617,3 +622,4 @@ int convert_to_scroll_position_tweak(PyObject *arg, void *dst) #endif +#endif diff --git a/plugins/pychrysalide/glibext/constants.h b/plugins/pychrysalide/glibext/constants.h index 4a4f6da..a950125 100644 --- a/plugins/pychrysalide/glibext/constants.h +++ b/plugins/pychrysalide/glibext/constants.h @@ -37,6 +37,8 @@ bool define_binary_portion_constants(PyTypeObject *); /* Tente de convertir en constante PortionAccessRights. */ int convert_to_portion_access_rights(PyObject *, void *); +#if 0 + /* Définit les constantes relatives aux lignes de tampon. */ bool define_buffer_line_constants(PyTypeObject *); @@ -68,6 +70,8 @@ int convert_to_scroll_position_tweak(PyObject *, void *); #endif +#endif + #endif /* _PLUGINS_PYCHRYSALIDE_GLIBEXT_CONSTANTS_H */ diff --git a/plugins/pychrysalide/glibext/module.c b/plugins/pychrysalide/glibext/module.c index 23e7a7d..e62d587 100644 --- a/plugins/pychrysalide/glibext/module.c +++ b/plugins/pychrysalide/glibext/module.c @@ -30,7 +30,6 @@ /* #include "binarycursor.h" -#include "binportion.h" #include "buffercache.h" #include "bufferline.h" #include "bufferview.h" @@ -42,6 +41,7 @@ #include "named.h" #include "singleton.h" */ +#include "portion.h" #include "work.h" #include "workqueue.h" #include "../helpers.h" @@ -110,6 +110,7 @@ bool populate_glibext_module(void) result = true; + if (result) result = ensure_python_binary_portion_is_registered(); if (result) result = ensure_python_generic_work_is_registered(); if (result) result = ensure_python_work_queue_is_registered(); @@ -117,7 +118,6 @@ bool populate_glibext_module(void) if (result) result = ensure_python_singleton_candidate_is_registered(); if (result) result = ensure_python_binary_cursor_is_registered(); - if (result) result = ensure_python_binary_portion_is_registered(); if (result) result = ensure_python_buffer_cache_is_registered(); if (result) result = ensure_python_buffer_line_is_registered(); #ifdef INCLUDE_GTK_SUPPORT diff --git a/plugins/pychrysalide/glibext/portion.c b/plugins/pychrysalide/glibext/portion.c index 70eb314..d95308c 100644 --- a/plugins/pychrysalide/glibext/portion.c +++ b/plugins/pychrysalide/glibext/portion.c @@ -1,6 +1,6 @@ /* Chrysalide - Outil d'analyse de fichiers binaires - * binportion.c - équivalent Python du fichier "glibext/gbinportion.c" + * portion.c - équivalent Python du fichier "glibext/portion.c" * * Copyright (C) 2019-2020 Cyrille Bagard * @@ -22,15 +22,14 @@ */ -#include "binportion.h" +#include "portion.h" #include <pygobject.h> #include <i18n.h> -#include <glibext/gbinportion-int.h> -#include <plugins/dt.h> +#include <glibext/portion-int.h> #include "constants.h" @@ -40,13 +39,13 @@ -/* Accompagne la création d'une instance dérivée en Python. */ -static PyObject *py_bin_portion_new(PyTypeObject *, PyObject *, PyObject *); +CREATE_DYN_CONSTRUCTOR(binary_portion, G_TYPE_BINARY_PORTION); + /* Initialise une instance sur la base du dérivé de GObject. */ -static int py_bin_portion_init(PyObject *, PyObject *, PyObject *); +static int py_binary_portion_init(PyObject *, PyObject *, PyObject *); -/* Effectue une comparaison avec un objet Python 'BinPortion'. */ +/* Effectue une comparaison avec un objet Python BinaryPortion. */ static PyObject *py_binary_portion_richcompare(PyObject *, PyObject *, int); /* Assure qu'une portion ne dépasse pas une position donnée. */ @@ -77,66 +76,6 @@ static int py_binary_portion_set_rights(PyObject *, PyObject *, void *); /****************************************************************************** * * -* Paramètres : type = type du nouvel objet à mettre en place. * -* args = éventuelle liste d'arguments. * -* kwds = éventuel dictionnaire de valeurs mises à disposition. * -* * -* Description : Accompagne la création d'une instance dérivée en Python. * -* * -* Retour : Nouvel objet Python mis en place ou NULL en cas d'échec. * -* * -* Remarques : - * -* * -******************************************************************************/ - -static PyObject *py_bin_portion_new(PyTypeObject *type, PyObject *args, PyObject *kwds) -{ - PyObject *result; /* Objet à retourner */ - PyTypeObject *base; /* Type de base à dériver */ - bool first_time; /* Evite les multiples passages*/ - GType gtype; /* Nouveau type de processeur */ - bool status; /* Bilan d'un enregistrement */ - - /* Validations diverses */ - - base = get_python_binary_portion_type(); - - if (type == base) - goto simple_way; - - /* Mise en place d'un type dédié */ - - first_time = (g_type_from_name(type->tp_name) == 0); - - gtype = build_dynamic_type(G_TYPE_BIN_PORTION, type->tp_name, NULL, NULL, NULL); - - if (first_time) - { - status = register_class_for_dynamic_pygobject(gtype, type); - - if (!status) - { - result = NULL; - goto exit; - } - - } - - /* On crée, et on laisse ensuite la main à PyGObject_Type.tp_init() */ - - simple_way: - - result = PyType_GenericNew(type, args, kwds); - - exit: - - return result; - -} - - -/****************************************************************************** -* * * Paramètres : self = objet à initialiser (théoriquement). * * args = arguments fournis à l'appel. * * kwds = arguments de type key=val fournis. * @@ -149,33 +88,30 @@ static PyObject *py_bin_portion_new(PyTypeObject *type, PyObject *args, PyObject * * ******************************************************************************/ -static int py_bin_portion_init(PyObject *self, PyObject *args, PyObject *kwds) +static int py_binary_portion_init(PyObject *self, PyObject *args, PyObject *kwds) { - const char *code; /* Identifiant de couleur */ vmpa2t *addr; /* Emplacement de portion */ unsigned long long size; /* Taille de la portion */ int ret; /* Bilan de lecture des args. */ - GBinPortion *portion; /* Portion à manipuler */ + GBinaryPortion *portion; /* Portion à manipuler */ - static char *kwlist[] = { "code", "addr", "size", NULL }; + static char *kwlist[] = { "addr", "size", NULL }; #define BINARY_PORTION_DOC \ - "The BinPortion object handles parts of binaries usually formally" \ + "The BinaryPortion object handles parts of binaries usually formally" \ " identified in binary formats, like program segments or sections for ELF" \ " files for example.\n" \ "\n" \ "Instances can be created using the following constructor:\n" \ "\n" \ - " BinPortion(code, addr, size)" \ + " BinaryPortion(addr, size)" \ "\n" \ - "Where code is the CSS class style for the rendering color to use, addr is" \ - " the starting point of the portion in memory, as a pychrysalide.arch.vmpa" \ - " value, and size is the size of the portion." \ + "Where *addr* is the starting point of the portion in memory, as a" \ + " pychrysalide.arch.vmpa value, and *size* is the size of the portion." /* Récupération des paramètres */ - ret = PyArg_ParseTupleAndKeywords(args, kwds, "sO&K", kwlist, - &code, convert_any_to_vmpa, &addr, &size); + ret = PyArg_ParseTupleAndKeywords(args, kwds, "O&K", kwlist, convert_any_to_vmpa, &addr, &size); if (!ret) return -1; /* Initialisation d'un objet GLib */ @@ -189,11 +125,13 @@ static int py_bin_portion_init(PyObject *self, PyObject *args, PyObject *kwds) /* Eléments de base */ - portion = G_BIN_PORTION(pygobject_get(self)); - - portion->code = strdup(code); + portion = G_BINARY_PORTION(pygobject_get(self)); - init_mrange(&portion->range, addr, size); + if (!g_binary_portion_create(portion, addr, size)) + { + clean_vmpa_arg(addr); + return -1; + } clean_vmpa_arg(addr); @@ -208,7 +146,7 @@ static int py_bin_portion_init(PyObject *self, PyObject *args, PyObject *kwds) * b = second object Python à consulter. * * op = type de comparaison menée. * * * -* Description : Effectue une comparaison avec un objet Python 'BinPortion'. * +* Description : Effectue une comparaison avec un objet Python BinaryPortion. * * * * Retour : Bilan de l'opération. * * * @@ -220,8 +158,8 @@ static PyObject *py_binary_portion_richcompare(PyObject *a, PyObject *b, int op) { PyObject *result; /* Bilan à retourner */ int ret; /* Bilan de lecture des args. */ - const GBinPortion *portion_a; /* Premier élément à traiter */ - const GBinPortion *portion_b; /* Second élément à traiter */ + const GBinaryPortion *portion_a; /* Premier élément à traiter */ + const GBinaryPortion *portion_b; /* Second élément à traiter */ int status; /* Résultat d'une comparaison */ ret = PyObject_IsInstance(b, (PyObject *)get_python_binary_portion_type()); @@ -231,8 +169,8 @@ static PyObject *py_binary_portion_richcompare(PyObject *a, PyObject *b, int op) goto cmp_done; } - portion_a = G_BIN_PORTION(pygobject_get(a)); - portion_b = G_BIN_PORTION(pygobject_get(b)); + portion_a = G_BINARY_PORTION(pygobject_get(a)); + portion_b = G_BINARY_PORTION(pygobject_get(b)); status = g_binary_portion_compare(&portion_a, &portion_b); @@ -265,16 +203,16 @@ static PyObject *py_binary_portion_limit_range(PyObject *self, PyObject *args) PyObject *result; /* Trouvailles à retourner */ unsigned long long max; /* Taille maximale à accorder */ int ret; /* Bilan de lecture des args. */ - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ bool status; /* Bilan de la modification */ -#define BINARY_SYMBOL_LIMIT_RANGE_METHOD PYTHON_METHOD_DEF \ +#define BINARY_PORTION_LIMIT_RANGE_METHOD PYTHON_METHOD_DEF \ ( \ limit_range, "$self, max, /", \ METH_VARARGS, py_binary_portion, \ "Ensure the portion range does not cross a boundary size.\n" \ "\n" \ - "An integer value is expected as the maximum size of the" \ + "An *max* integer value is expected as the maximum size of the" \ " portion.\n" \ "\n" \ "A boolean value indicating the success of the operation is" \ @@ -284,7 +222,7 @@ static PyObject *py_binary_portion_limit_range(PyObject *self, PyObject *args) ret = PyArg_ParseTuple(args, "K", &max); if (!ret) return NULL; - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); status = g_binary_portion_limit_range(portion, max); @@ -311,24 +249,27 @@ static PyObject *py_binary_portion_limit_range(PyObject *self, PyObject *args) static PyObject *py_binary_portion_include(PyObject *self, PyObject *args) { - GBinPortion *sub; /* Sous-portion à inclure */ + GBinaryPortion *sub; /* Sous-portion à inclure */ int ret; /* Bilan de lecture des args. */ - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ -#define BINARY_SYMBOL_INCLUDE_METHOD PYTHON_METHOD_DEF \ -( \ - include, "$self, sub, /", \ - METH_VARARGS, py_binary_portion, \ - "Include another binary portion as a child item.\n" \ - "\n" \ - "The sub portion has to be a pychrysalide.glibext.BinPortion" \ - " instance." \ +#define BINARY_PORTION_INCLUDE_METHOD PYTHON_METHOD_DEF \ +( \ + include, "$self, sub, /", \ + METH_VARARGS, py_binary_portion, \ + "Include another binary portion as a child item.\n" \ + "\n" \ + "The provided *sub* portion has to be a" \ + " pychrysalide.glibext.BinaryPortion instance." \ + "\n" \ + "The returned value is a boolean value providing the" \ + " status of the operation." \ ) ret = PyArg_ParseTuple(args, "O&", convert_to_binary_portion, &sub); if (!ret) return NULL; - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); g_object_ref(G_OBJECT(sub)); g_binary_portion_include(portion, sub); @@ -354,7 +295,7 @@ static PyObject *py_binary_portion_include(PyObject *self, PyObject *args) static PyObject *py_binary_portion_get_desc(PyObject *self, void *closure) { PyObject *result; /* Résultat à retourner */ - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ const char *desc; /* Description récupérée */ #define BINARY_PORTION_DESC_ATTRIB PYTHON_GETSET_DEF_FULL \ @@ -364,7 +305,7 @@ static PyObject *py_binary_portion_get_desc(PyObject *self, void *closure) " simple string." \ ) - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); desc = g_binary_portion_get_desc(portion); @@ -391,7 +332,7 @@ static PyObject *py_binary_portion_get_desc(PyObject *self, void *closure) static int py_binary_portion_set_desc(PyObject *self, PyObject *value, void *closure) { - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ const char *desc; /* Description à définir */ if (!PyUnicode_Check(value)) @@ -400,7 +341,7 @@ static int py_binary_portion_set_desc(PyObject *self, PyObject *value, void *clo return -1; } - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); desc = PyUnicode_DATA(value); @@ -427,7 +368,7 @@ static int py_binary_portion_set_desc(PyObject *self, PyObject *value, void *clo static PyObject *py_binary_portion_get_range(PyObject *self, void *closure) { PyObject *result; /* Résultat à retourner */ - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ const mrange_t *range; /* Espace de couverture */ #define BINARY_PORTION_RANGE_ATTRIB PYTHON_GET_DEF_FULL \ @@ -438,7 +379,7 @@ static PyObject *py_binary_portion_get_range(PyObject *self, void *closure) "This property is a pychrysalide.arch.mrange instance." \ ) - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); range = g_binary_portion_get_range(portion); @@ -465,7 +406,7 @@ static PyObject *py_binary_portion_get_range(PyObject *self, void *closure) static PyObject *py_binary_portion_get_continuation(PyObject *self, void *closure) { PyObject *result; /* Résultat à retourner */ - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ bool status; /* Bilan d'une consultation */ #define BINARY_PORTION_CONTINUATION_ATTRIB PYTHON_GETSET_DEF_FULL \ @@ -478,7 +419,7 @@ static PyObject *py_binary_portion_get_continuation(PyObject *self, void *closur " several parts when included in the portion tree." \ ) - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); status = g_binary_portion_is_continuation(portion); @@ -506,7 +447,7 @@ static PyObject *py_binary_portion_get_continuation(PyObject *self, void *closur static int py_binary_portion_set_continuation(PyObject *self, PyObject *value, void *closure) { - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ bool status; /* Valeur à manipuler */ if (!PyBool_Check(value)) @@ -515,7 +456,7 @@ static int py_binary_portion_set_continuation(PyObject *self, PyObject *value, v return -1; } - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); status = (value == Py_True); @@ -542,17 +483,17 @@ static int py_binary_portion_set_continuation(PyObject *self, PyObject *value, v static PyObject *py_binary_portion_get_rights(PyObject *self, void *closure) { PyObject *result; /* Résultat à retourner */ - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ PortionAccessRights rights; /* Bilan d'une consultation */ #define BINARY_PORTION_RIGHTS_ATTRIB PYTHON_GETSET_DEF_FULL \ ( \ rights, py_binary_portion, \ "Access rights declared for the binary portion, as a" \ - " pychrysalide.glibext.BinPortion.PortionAccessRights value." \ + " pychrysalide.glibext.BinaryPortion.PortionAccessRights value."\ ) - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); rights = g_binary_portion_get_rights(portion); @@ -579,13 +520,13 @@ static PyObject *py_binary_portion_get_rights(PyObject *self, void *closure) static int py_binary_portion_set_rights(PyObject *self, PyObject *value, void *closure) { - GBinPortion *portion; /* Version GLib du type */ + GBinaryPortion *portion; /* Version GLib du type */ PortionAccessRights rights; /* Valeur à manipuler */ if (convert_to_portion_access_rights(value, &rights) != 1) return -1; - portion = G_BIN_PORTION(pygobject_get(self)); + portion = G_BINARY_PORTION(pygobject_get(self)); g_binary_portion_set_rights(portion, rights); @@ -609,8 +550,8 @@ static int py_binary_portion_set_rights(PyObject *self, PyObject *value, void *c PyTypeObject *get_python_binary_portion_type(void) { static PyMethodDef py_binary_portion_methods[] = { - BINARY_SYMBOL_LIMIT_RANGE_METHOD, - BINARY_SYMBOL_INCLUDE_METHOD, + BINARY_PORTION_LIMIT_RANGE_METHOD, + BINARY_PORTION_INCLUDE_METHOD, { NULL } }; @@ -626,7 +567,7 @@ PyTypeObject *get_python_binary_portion_type(void) PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "pychrysalide.glibext.BinPortion", + .tp_name = "pychrysalide.glibext.BinaryPortion", .tp_basicsize = sizeof(PyGObject), .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, @@ -638,8 +579,8 @@ PyTypeObject *get_python_binary_portion_type(void) .tp_methods = py_binary_portion_methods, .tp_getset = py_binary_portion_getseters, - .tp_init = py_bin_portion_init, - .tp_new = py_bin_portion_new, + .tp_init = py_binary_portion_init, + .tp_new = py_binary_portion_new, }; @@ -652,7 +593,7 @@ PyTypeObject *get_python_binary_portion_type(void) * * * Paramètres : module = module dont la définition est à compléter. * * * -* Description : Prend en charge l'objet 'pychrysalide.glibext.BinPortion'. * +* Description : Prend en charge l'objet 'pychrysalide.glibext.BinaryPortion'.* * * * Retour : Bilan de l'opération. * * * @@ -662,7 +603,7 @@ PyTypeObject *get_python_binary_portion_type(void) bool ensure_python_binary_portion_is_registered(void) { - PyTypeObject *type; /* Type Python 'BinPortion' */ + PyTypeObject *type; /* Type Python 'BinaryPortion' */ PyObject *module; /* Module à recompléter */ PyObject *dict; /* Dictionnaire du module */ @@ -674,7 +615,7 @@ bool ensure_python_binary_portion_is_registered(void) dict = PyModule_GetDict(module); - if (!register_class_for_pygobject(dict, G_TYPE_BIN_PORTION, type)) + if (!register_class_for_pygobject(dict, G_TYPE_BINARY_PORTION, type)) return false; if (!define_binary_portion_constants(type)) @@ -718,7 +659,7 @@ int convert_to_binary_portion(PyObject *arg, void *dst) break; case 1: - *((GBinPortion **)dst) = G_BIN_PORTION(pygobject_get(arg)); + *((GBinaryPortion **)dst) = G_BINARY_PORTION(pygobject_get(arg)); break; default: diff --git a/plugins/pychrysalide/glibext/portion.h b/plugins/pychrysalide/glibext/portion.h index b27c8ea..a417c01 100644 --- a/plugins/pychrysalide/glibext/portion.h +++ b/plugins/pychrysalide/glibext/portion.h @@ -1,8 +1,8 @@ /* Chrysalide - Outil d'analyse de fichiers binaires - * binportion.h - prototypes pour l'équivalent Python du fichier "glibext/gbinportion.h" + * portion.h - prototypes pour l'équivalent Python du fichier "glibext/portion.h" * - * Copyright (C) 2019 Cyrille Bagard + * Copyright (C) 2019-2024 Cyrille Bagard * * This file is part of Chrysalide. * @@ -22,8 +22,8 @@ */ -#ifndef _PLUGINS_PYCHRYSALIDE_GLIBEXT_BINPORTION_H -#define _PLUGINS_PYCHRYSALIDE_GLIBEXT_BINPORTION_H +#ifndef _PLUGINS_PYCHRYSALIDE_GLIBEXT_PORTION_H +#define _PLUGINS_PYCHRYSALIDE_GLIBEXT_PORTION_H #include <Python.h> @@ -34,7 +34,7 @@ /* Fournit un accès à une définition de type à diffuser. */ PyTypeObject *get_python_binary_portion_type(void); -/* Prend en charge l'objet 'pychrysalide.glibext.BinPortion'. */ +/* Prend en charge l'objet 'pychrysalide.glibext.BinaryPortion'. */ bool ensure_python_binary_portion_is_registered(void); /* Tente de convertir en portion de binaire. */ @@ -42,4 +42,4 @@ int convert_to_binary_portion(PyObject *, void *); -#endif /* _PLUGINS_PYCHRYSALIDE_GLIBEXT_BINPORTION_H */ +#endif /* _PLUGINS_PYCHRYSALIDE_GLIBEXT_PORTION_H */ |