On Tue, 21 Jan 1997, Daniel Koepke wrote:
> Tests if an assertion is false, and if so, aborts. Similar to:
>
> if (sizeof(header_block_type) != BLOCK_SIZE) {
> fprintf(stdout, "ASSERTION FAILED: mail.c line 208\n");
> abort();
> }
>
> I dunno the reasoning for the assert() in the stock code.
>
As you are probably well aware, asserts are a great way to test your
code, usually after its out of your hands. Which would you prefer, an
end-user calling you up and saying "When I do xyz it says Segmentation
fault, core dumped and stops working", or an end-user calling you up and
telling you that the program says "Assert failed in module abc line xxx".
If you know where the bug is immediately, its a lot easier to fix. :)
This assert is probably to make sure that there is enough scratch space
for the mail to be sent, however I've never seen it happen before, and so
my premise would be that the cause of the assert failure would be
something other than stock circle code (probably that nasty OasisOLC
patch :) )
Rich
+-----------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
| http://cspo.queensu.ca/~fletcher/Circle/list_faq.html |
+-----------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/18/00 PST