From 131d8f5d34c2deb5d9951503d52211338ad04bb9 Mon Sep 17 00:00:00 2001 From: Ken Murchison Date: Thu, 25 Apr 2024 18:35:20 -0400 Subject: [PATCH] vcardparser.c: debugging fprintf for PE_MISMATCHED_CARD --- src/libicalvcard/vcardparser.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/libicalvcard/vcardparser.c b/src/libicalvcard/vcardparser.c index 034ebb41d..afad2eff8 100755 --- a/src/libicalvcard/vcardparser.c +++ b/src/libicalvcard/vcardparser.c @@ -883,6 +883,7 @@ static int _parse_vcard(struct vcardparser_state *state, if (kind == VCARD_NO_COMPONENT) { state->itemstart = cardstart; + fprintf(stderr, "BEGIN with unknown kind\n"); r = PE_MISMATCHED_CARD; break; } @@ -898,6 +899,7 @@ static int _parse_vcard(struct vcardparser_state *state, else if (!comp) { /* no comp means we're at the top level, haven't seen a BEGIN! */ state->itemstart = cardstart; + fprintf(stderr, "toplevel with no BEGIN\n"); r = PE_MISMATCHED_CARD; break; } @@ -910,6 +912,7 @@ static int _parse_vcard(struct vcardparser_state *state, /* special case mismatched card, the "start" was the start of * the card */ state->itemstart = cardstart; + fprintf(stderr, "BEGIN comp != END\n"); r = PE_MISMATCHED_CARD; }