[PATCH v3 02/10] shell32/autocomplete: Handle heap_alloc failure

Huw Davies huw at codeweavers.com
Mon Sep 10 09:36:17 CDT 2018


On Mon, Sep 10, 2018 at 05:29:51PM +0300, Gabriel Ivăncescu wrote:
> On Mon, Sep 10, 2018 at 2:54 PM, Gabriel Ivăncescu
> <gabrielopcode at gmail.com> wrote:
> > On Mon, Sep 10, 2018 at 11:40 AM, Huw Davies <huw at codeweavers.com> wrote:
> >>
> >> Changing the type of len and making moving the declaration into an
> >> assignment don't belong in this patch.  What you really want here
> >> is a check against LB_ERR, but that again is a different patch.
> >>
> > Oh I thought they were way too trivial changes to make in a separate
> > patch, sorry. Though, indeed I'll add a check for LB_ERR in an extra
> > patch then.
> >
> 
> On second thought, it looks like all the LB_GETTEXTLEN are done after
> LB_GETCURSEL, so they should never be able to fail (an invalid
> selection is already checked before that).
> 
> Should I still check for LB_ERR? Or just send an extra patch that
> converts int to UINT for len without the checks?

Just leave them as ints.

Huw.



More information about the wine-devel mailing list