Re: [BUFFER] Bufffer overflow

From: Peter Ajamian (peter@pajamian.dhs.org)
Date: 08/11/00


I wrote:
>
> Nahhh, just increase the size of MAX_STRING_LENGTH, or you can do
> something more complex which allocates the memory dynamically and
> reallocates to keep it from overflowing (I actually made up an entire
> system around this concept so I don't have to waste memory for
> everything that uses MAX_STRING_LENGTH or use cheesy workarounds like
> limiting the amount of output to a command, it works pretty well I can
> actually do a "rlist 0 100000" and it will page the entire thing,
> around
> 50 pages worth, to the screen properly without limiting the number of
> lines and without seg faulting).


And then Shane Lee wrote:
>
> Hrmm, that sound's cool. Got a snippet or just some generic tips on
> how I could do the same?
> I got cheesy and coded checks in all the imm commands that allowed
> overflows and segmentation faults (i.e. "Sorry, you can't access more
> than 200 vnums at the same time" when someone types 'olist 1 9999').
> Problem was, I had to chase them all down. That really sucked:P

I'm working on a snippet right now, I'll post it up to the list in a few
minutes when I'm done with it.

Regards, Peter


     +------------------------------------------------------------+
     | 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/11/01 PDT