- ++ret->num_internet;
- if (strlen(ret->recp_internet) > 0) {
- strcat(ret->recp_internet, "|");
+ /* Yes, you're reading this correctly: if the target
+ * domain points back to the local system or an attached
+ * Citadel directory, the address is invalid. That's
+ * because if the address were valid, we would have
+ * already translated it to a local address by now.
+ */
+ if (IsDirectory(this_recp)) {
+ ++ret->num_error;
+ invalid = 1;
+ }
+ else {
+ ++ret->num_internet;
+ if (strlen(ret->recp_internet) > 0) {
+ strcat(ret->recp_internet, "|");
+ }
+ strcat(ret->recp_internet, this_recp);