------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1295




--- Comment #24 from Philip Hazel <[email protected]>  2012-10-20 18:54:08 
---
On Sat, 20 Oct 2012, Zoltan Herczeg wrote:

> I fixed the issue in study:
> 
>  #if defined SUPPORT_UTF || !defined COMPILE_PCRE8
>      case OP_XCLASS:
> -    cc += GET(cc, 1) - PRIV(OP_lengths)[OP_CLASS];
> +    cc += GET(cc, 1);
> +    cc -= PRIV(OP_lengths)[OP_CLASS];
>      /* Fall through */
>  #endif
> 
> If GET(cc, 1) < PRIV(OP_lengths)[OP_CLASS], the result overflows in 64 bit 
> mode
> (both are unsigned values). Unfortunately I still see crashes in 64 bit mode
> (when 32 bit tests are running). Perhaps a similar issue.

I think that is worth a comment in the code to stop somebody from 
"tidying" it up. And wouldn't this be neater?

     cc = (cc + GET(cc, 1)) - PRIV(OP_lengths)[OP_CLASS];

Philip


-- 
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

-- 
## List details at https://lists.exim.org/mailman/listinfo/pcre-dev 

Reply via email to