[PATCH v11 0/7] MR337: winepulse: Return device-specific values for GetMixFormat and GetDevicePeriod

Huw Davies (@huw) wine at gitlab.winehq.org
Tue Jul 5 10:02:46 CDT 2022


Huw Davies (@huw) commented about dlls/winepulse.drv/pulse.c:
>      if (FAILED(hr))
>          goto exit;
>  
> -    period = pulse_def_period[stream->dataflow == eCapture];
> +    period = 0;
> +    if (FAILED(get_device_period_helper(params->dataflow, params->pulse_name, &period, NULL))) {
> +        pulse_unlock();
> +        params->result = E_FAIL;
> +        return STATUS_SUCCESS;
> +    }
```suggestion:-4+0
    if (FAILED(hr = get_device_period_helper(params->dataflow, params->pulse_name, &period, NULL)))
        goto exit;
```
But, there's an existing issue in the failure path under `exit:` (`free(stream)` should move out from the `if(stream->stream)` block).  So perhaps fix this issue in a separate commit before this one.

-- 
https://gitlab.winehq.org/wine/wine/-/merge_requests/337#note_3360



More information about the wine-devel mailing list