diff options
Diffstat (limited to 'src/analysis')
| -rw-r--r-- | src/analysis/binary.c | 13 | 
1 files changed, 13 insertions, 0 deletions
diff --git a/src/analysis/binary.c b/src/analysis/binary.c index f13a887..15be43e 100644 --- a/src/analysis/binary.c +++ b/src/analysis/binary.c @@ -445,6 +445,7 @@ GOpenidaBinary *g_openida_binary_new_from_file(const char *filename)  GOpenidaBinary *g_openida_binary_new_from_xml(xmlXPathContextPtr context, const char *path)  {      GOpenidaBinary *result;                 /* Adresse à retourner         */ +    char *type;                             /* Tupe de binaire à charger   */      size_t access_len;                      /* Taille d'un chemin interne  */      char *access;                           /* Chemin pour une sous-config.*/      char *filename;                         /* Chemin du binaire à charger */ @@ -456,6 +457,14 @@ GOpenidaBinary *g_openida_binary_new_from_xml(xmlXPathContextPtr context, const      result = NULL; +    /* Type */ + +    type = get_node_prop_value(context, path, "type"); + +    printf("###type### %s\n", type); + +    free(type); +      /* Chemin du fichier à retrouver */      access = strdup(path); @@ -627,6 +636,10 @@ bool g_openida_binary_save(const GOpenidaBinary *binary, xmlDocPtr xdoc, xmlXPat      result = true; +    /* Type */ + +    result &= add_string_attribute_to_node(xdoc, context, path, "type", "file"); +      /* Nom du fichier associé */      access = strdup(path);  | 
