RICHED20: EM_SETCHARFORMAT must return 0, not assert, on invalid struct size (try 3)

a_villacis at a_villacis at
Wed Sep 26 12:58:24 CDT 2007

> a_villacis at writes:
>> I considered doing this at first, but ME_ToCF2W is used in three other
>> places beside handling EM_SETCHARFORMAT (all in style.c), and those
>> places
>> might get a null-pointer exception instead of an assert if something
>> went
>> wrong.
> A null-pointer exception serves the same purpose as an assert, and
> they both result in a debugger backtrace, so there's no reason to add
> more asserts here.
> --
> Alexandre Julliard
> julliard at

Now without new asserts.

* EM_SETCHARFORMAT must not assert on invalid structure size. Instead,
  it should just fail and return 0.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: wine-riched20-EM_SETCHARFORMAT-no-assert-try3.patch
Type: text/x-patch
Size: 4616 bytes
Desc: not available
Url : 

More information about the wine-patches mailing list