ID:936863
 
Keywords: count, dec, inc, ref
I poked through search results and didn't find an actual description of the circumstances under which it happens, so what exactly causes an IncRefCount/DecRefCount error? I get umpteen of these in the Daemon log during game runtime:

BUG: Bad savefile in DecRefCount(0)
BUG: Bad ref (f:2153) in IncRefCount(DM atoms.dm:1243)
BUG: Bad ref (f:2153) in IncRefCount(DM atoms.dm:1244)
BUG: Bad ref (f:2153) in DecRefCount(DM atoms.dm:1244)
BUG: Finished erasure with refcount=1 (ref=3:44) DM (client.dm:774)
BUG: Bad savefile in DecRefCount(0)
BUG: Finished erasure with refcount=1 (ref=5:5) DM (:0)
BUG: Finished erasure with refcount=1 (ref=3:44) DM (client.dm:774)
BUG: Bad savefile in DecRefCount(0)
BUG: Finished erasure with refcount=1 (ref=3:44) DM (client.dm:774)
BUG: Bad savefile in DecRefCount(0)


..and from what I gather, the first digit in the refcount errors corresponds to specific datum types, so what are 3 and 5?

It always seems like I catch these errors after I change something, and going to the line number in the errors never seems to be near anything obvious (since I assumed new and del are the source of these).
You can check this out by using the \ref text macro.

1 is turfs
2 is objs
3 is mobs
4 is areas
5 is clients