stef...@apache.org writes:

> Author: stefan2
> Date: Wed Oct 31 14:19:59 2012
> New Revision: 1404159
>
> URL: http://svn.apache.org/viewvc?rev=1404159&view=rev
> Log:
> "Harden" our named atomics against data file corruption.  Even if
> the memory block contains completely random data,  we shall never
> see an access outside that buffer.

> +      /* Sanitize (in case of data corruption)
> +       */
> +      if (new_ns->data->count > MAX_ATOMIC_COUNT)
> +        new_ns->data->count = MAX_ATOMIC_COUNT;

I'm still seeing a crash:

467           if (new_ns->data->count > MAX_ATOMIC_COUNT)
(gdb) p new_ns->data->count
$1 = -1382404098

I suppose we could either test "count < 0" or make count unsigned?

-- 
Certified & Supported Apache Subversion Downloads:
http://www.wandisco.com/subversion/download

Reply via email to