> OBSomethingElse: > Another thing about FreeBSD (I've not tried the other *BSD's) is it's > free(), e.g. I've fought for some time with a bug of freeing a > nullpointer, compiled under Linux mud simply crashed with a sigfault, > FreeBSD ran on as if nothing had happend. Investigating this, I found that > at least FreeBSD looks at what you're trying to Free, and if it is "null", > it decides "Why free it then??", perhaps in some opinions not the best > solution. > > But it made me wonder, how to make a Circle-Free, ie, imitiate the FreeBSD > free. Actually, I thought about doing this too, but it quickly turned into a "well, if I'm going to do that, why don't I write up a registar for memory allocation, and then sync it to that chart to insure I don't free any thing that's not supposed to be freed (dangling pointers, etc)". And then, I thought, "Wait, I can have it verify number of uses on that pointer, and then automatically free it when nothings using it anymore". And then I said, what a pain in the ass, and downloaded a copy of the Bohem GC (garbage collection) library, which among other things, frees anything that is no longer referenced (even some types of circular referencing), as well as allows you to override the free() function in a decent number of ways. Check archives for previous conversations along this topic though. PjD +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/10/01 PDT