diff options
Diffstat (limited to 'activitypub.c')
| -rw-r--r-- | activitypub.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/activitypub.c b/activitypub.c index 8127e8d..51ae6fa 100644 --- a/activitypub.c +++ b/activitypub.c | |||
| @@ -564,6 +564,7 @@ int process_message(snac *snac, char *msg, char *req) | |||
| 564 | char *actor = xs_dict_get(msg, "actor"); | 564 | char *actor = xs_dict_get(msg, "actor"); |
| 565 | char *type = xs_dict_get(msg, "type"); | 565 | char *type = xs_dict_get(msg, "type"); |
| 566 | xs *actor_o = NULL; | 566 | xs *actor_o = NULL; |
| 567 | int a_status; | ||
| 567 | 568 | ||
| 568 | char *object, *utype; | 569 | char *object, *utype; |
| 569 | 570 | ||
| @@ -574,8 +575,17 @@ int process_message(snac *snac, char *msg, char *req) | |||
| 574 | utype = "(null)"; | 575 | utype = "(null)"; |
| 575 | 576 | ||
| 576 | /* bring the actor */ | 577 | /* bring the actor */ |
| 577 | if (!valid_status(actor_request(snac, actor, &actor_o))) { | 578 | a_status = actor_request(snac, actor, &actor_o); |
| 578 | snac_log(snac, xs_fmt("error requesting actor %s -- retry later", actor)); | 579 | |
| 580 | /* if it's a 410 Gone, it's a Delete crap that can be ignored */ | ||
| 581 | if (a_status == 410) { | ||
| 582 | return 1; | ||
| 583 | } | ||
| 584 | |||
| 585 | if (!valid_status(a_status)) { | ||
| 586 | snac_log(snac, | ||
| 587 | xs_fmt("error requesting actor %s %d -- retry later", actor, a_status)); | ||
| 588 | |||
| 579 | return 0; | 589 | return 0; |
| 580 | } | 590 | } |
| 581 | 591 | ||