Skip to content

Commit

Permalink
Merge branch 'master' of /srv/git/r/doldaconnect
Browse files Browse the repository at this point in the history
  • Loading branch information
dolda2000 committed May 22, 2012
2 parents 0a19599 + f079b16 commit d693252
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions clients/gtk2/hublist-xml.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,12 +175,18 @@ int pubhubxmlhandler(int op, char *buf, size_t len)
attr = (char *)xmlGetProp(n, (xmlChar *)names[i]);
if(attr != NULL)
{
if(types[i] == G_TYPE_STRING)
if(!strcmp(names[i], "Address")) {
if(!strncmp(attr, "dchub://", 8))
gtk_list_store_set(model, &iter, i, attr + 8, -1);
else
gtk_list_store_set(model, &iter, i, attr, -1);
} else if(types[i] == G_TYPE_STRING) {
gtk_list_store_set(model, &iter, i, attr, -1);
else if(types[i] == G_TYPE_INT)
} else if(types[i] == G_TYPE_INT) {
gtk_list_store_set(model, &iter, i, atoi(attr), -1);
else if(types[i] == G_TYPE_INT64)
} else if(types[i] == G_TYPE_INT64) {
gtk_list_store_set(model, &iter, i, strtoll(attr, NULL, 0), -1);
}
xmlFree(attr);
}
}
Expand Down

0 comments on commit d693252

Please sign in to comment.