mmdevapi: Prevent 64 bit overflow within a few days of audio device use. (try 2)

Joerg-Cyril.Hoehle at t-systems.com Joerg-Cyril.Hoehle at t-systems.com
Fri Mar 1 08:06:04 CST 2013


Michael Stefaniuc wrote:
>My idea was to have the whole if else in an inline function.

That's understandable.  However in this particular case, we know that in Wine 
QueryPerfFrequency now yields 10000000, thus Muldiv64 is dead code actually.
So I decided to keep the
if (freq == 10000000) return idem;
in the main code and delegate the unused MulDiv to an auxiliary.

In winmm:waveform, things are a little different, and I was indeed considering
integrating the if (num==den) /* typically num = den = samples per second */
into the MulDiv64, should I add one there too.

A general purpose MulDiv however, should not waste cycles performing this particular check.

Regards,
 Jörg Höhle




More information about the wine-devel mailing list