diff --git a/mbfido/areamgr.c b/mbfido/areamgr.c index 0d1af2d6..4e31f521 100644 --- a/mbfido/areamgr.c +++ b/mbfido/areamgr.c @@ -763,6 +763,11 @@ void A_Connect(faddr *t, char *Area, FILE *tmp) Area[i]=toupper(Area[i]); if (!SearchMsgs(Area)) { + /* + * Close noderecord, autocreate will destroy it. + */ + UpdateNode(); + Syslog('m', " Area not found, trying to create"); temp = calloc(PATH_MAX, sizeof(char)); sprintf(temp, "%s/etc/mgroups.data", getenv("MBSE_ROOT")); diff --git a/mbfido/createm.c b/mbfido/createm.c index f8a73c65..e186ce5f 100644 --- a/mbfido/createm.c +++ b/mbfido/createm.c @@ -82,7 +82,8 @@ int create_msgarea(char *marea, faddr *p_from) * 0 - All Seems Well * 1 - Some error * - * The current nodes record may be destroyed after this! + * The current nodes record may be destroyed after this, + * make sure it is saved. */ int CheckEchoGroup(char *Area, int SendUplink, faddr *f) { diff --git a/mbfido/tosspkt.c b/mbfido/tosspkt.c index a3cd2191..52d16a0a 100644 --- a/mbfido/tosspkt.c +++ b/mbfido/tosspkt.c @@ -205,6 +205,7 @@ int importmsg(faddr *p_from, faddr *f, faddr *t, char *orig, char *subj, } if (!SearchMsgs(marea)) { + UpdateNode(); Syslog('m', "Unknown echo area %s", marea); if (!create_msgarea(marea, p_from)) { WriteError("Create echomail area %s failed", marea); @@ -215,6 +216,7 @@ int importmsg(faddr *p_from, faddr *f, faddr *t, char *orig, char *subj, free(buf); return 4; } + SearchNode(Link.aka); if (!SearchMsgs(marea)) { WriteError("Unknown echo area %s", marea); echo_bad++;