g_hash_table_insert(module_valid_length_hash,GINT_TO_POINTER(module->length),NULL);
}
- if (strcmp(module->type,"cabinet")) {
+ if (strcmp((const char *)module->type,"cabinet")) {
if (module->priority>captivemodid_module_type_best_priority_lookup(module->type)) {
module_type_best_priority_hash_init();
g_hash_table_insert(module_type_best_priority_hash,
{
xmlChar *r;
- if (!(r=xmlTextReaderGetAttribute(xml_reader,attr_name))) {
+ if (!(r=xmlTextReaderGetAttribute(xml_reader,BAD_CAST attr_name))) {
/* FIXME: File line identification? */
g_warning(_("%s: Undefined attributes: %s"),captivemodid_pathname,attr_name);
return NULL;
if (!(string=captivemodid_load_module_xml_get_attr(captivemodid_pathname,xml_reader,attr_name)))
return num_min-1;
- r=strtol(string,&ends,0);
+ r=strtol((const char *)string,&ends,0);
xmlFree(string);
if (r<num_min || r>num_max) {
g_warning(_("%s: Numer of out range %ld..%ld: %ld"),captivemodid_pathname,num_min,num_max,r);
goto fail_free_module;
if (!(module->md5 =captivemodid_load_module_xml_get_attr(captivemodid_pathname,xml_reader,"md5")))
goto fail_free_module;
- if (strlen(module->md5)!=strspn(module->md5,"0123456789abcdef")) {
+ if (strlen((const char *)module->md5)!=strspn((const char *)module->md5,"0123456789abcdef")) {
g_warning(_("%s: Attribute 'md5' can be only lower-cased hexstring: %s"),captivemodid_pathname,module->md5);
goto fail_free_module;
}
- if (strlen(module->md5)!=32) {
+ if (strlen((const char *)module->md5)!=32) {
g_warning(_("%s: Attribute 'md5' length must be 32: %s"),captivemodid_pathname,module->md5);
goto fail_free_module;
}
if (0>=(module->length=captivemodid_load_module_xml_get_attr_l(
captivemodid_pathname,xml_reader,"length",1,G_MAXINT-1)))
goto fail_free_module;
- if (!(cabinet_used_string=xmlTextReaderGetAttribute(xml_reader,"cabinet_used")))
+ if (!(cabinet_used_string=xmlTextReaderGetAttribute(xml_reader,BAD_CAST "cabinet_used")))
module->cabinet_used=0;
else {
xmlFree(cabinet_used_string);
g_return_if_fail(captivemodid_module_best_priority_notify!=NULL);
- (*captivemodid_module_best_priority_notify)(type);
+ (*captivemodid_module_best_priority_notify)((const gchar *)type);
}
void (*captivemodid_module_best_priority_notify)(const gchar *module_type);
const xmlChar *xml_name;
xml_name=xmlTextReaderName(xml_reader);
- /**/ if (!xmlStrcmp(xml_name,"modid")) { /* root tag */
+ /**/ if (!xmlStrcmp(xml_name,BAD_CAST "modid")) { /* root tag */
}
- else if (!xmlStrcmp(xml_name,"module"))
+ else if (!xmlStrcmp(xml_name,BAD_CAST "module"))
captivemodid_load_module_xml(captivemodid_pathname,xml_reader);
else g_warning(_("%s: Unknown ELEMENT node: %s"),captivemodid_pathname,xml_name);
xmlFree((xmlChar *)xml_name);