From: Martin Mares Date: Tue, 2 Jun 2015 13:20:35 +0000 (+0200) Subject: XML import now skips elements marked as deleted X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=93398aff7bcfaa7f4213d255351383bf375d1ae3;p=leo.git XML import now skips elements marked as deleted --- diff --git a/xml.c b/xml.c index 69e739d..04c8948 100644 --- a/xml.c +++ b/xml.c @@ -151,6 +151,11 @@ static void h_error(struct xml_context *ctx) static void parse_element(struct xml_context *ctx, struct xml_node *e) { + // JOSM marks deleted, but not uploaded, objects + char *action = xml_attr_value(ctx, e, "action"); + if (action && !strcmp(action, "delete")) + return; + if (!strcmp(e->name, "node")) parse_node(ctx, e); else if (!strcmp(e->name, "way"))