[1247] in Moira
dbck deletes referenced strings
daemon@ATHENA.MIT.EDU (David K Krikorian)
Sun Jan 24 09:47:49 1999
Date: Sun, 24 Jan 1999 09:47:45 -0500 (EST)
From: David K Krikorian <dkk@MIT.EDU>
To: bug-moira@MIT.EDU
There appears to be a bug in the dbck code to deal with string
duplicates. I don't know if it was there when I wrote it, but it
cropped up in this year's purge.
It looks to me that if we have a duplicate string, and iff we're not
fixing (remapping) duplicate strings, those duplicates (the higher-id
strings of a set of duplicates) show up as "unregistered" (i.e. the
refcount doesn't get incremented) and the higher-id strings get
deleted, even though they are still in use. (Unless they're used as
email forwarding addresses, but that's a minor detail. :-)
If I'm right, the following completely-untested change to phase2.pc
should fix this bug in dbck.
--
David Krikorian <dkk@mit.edu>, radio: KA1NAP, groups: APO LSC SIPB Grey17
*** phase2.pc.orig Sun Jan 24 09:34:29 1999
--- phase2.pc Sun Jan 24 09:36:33 1999
***************
*** 248,253 ****
--- 248,257 ----
string_check(newid);
doit = 1;
}
+ else
+ {
+ string_check(ret);
+ }
}
else if (!string_check(ret))
{
***************
*** 327,332 ****
--- 331,340 ----
ret = newid;
string_check(newid);
doit = 1;
+ }
+ else
+ {
+ string_check(ret);
}
}
else if (!string_check(ret))