https://git.reactos.org/?p=reactos.git;a=commitdiff;h=69cd1ebbbd3ea4a248e92…
commit 69cd1ebbbd3ea4a248e923a9ece01c6001293d9f
Author: Mark Jansen <mark.jansen(a)reactos.org>
AuthorDate: Sun Aug 18 19:13:04 2019 +0200
Commit: Mark Jansen <mark.jansen(a)reactos.org>
CommitDate: Tue Aug 20 22:31:55 2019 +0200
[TIMEOUT] Use Int32x32To64 instead of __emul
---
base/applications/cmdutils/timeout/timeout.c | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/base/applications/cmdutils/timeout/timeout.c b/base/applications/cmdutils/timeout/timeout.c
index 129a0f1ac9f..7aaddfbf5ad 100644
--- a/base/applications/cmdutils/timeout/timeout.c
+++ b/base/applications/cmdutils/timeout/timeout.c
@@ -155,16 +155,7 @@ INT InputWait(BOOL bNoBreak, INT timerValue)
timeElapsed = GetTickCount() - dwStartTime;
if (timeElapsed < 1000)
{
- /*
- * For whatever reason, x86 MSVC generates a ntdll!_allmul
- * call when using Int32x32To64(), instead of an imul
- * instruction. This leads the linker to error that _allmul
- * is missing, since we do not link against ntdll.
- * Everything is however OK with GCC...
- * We therefore use the __emul() intrinsic which does
- * the correct job.
- */
- DueTime.QuadPart = __emul(1000 - timeElapsed, -10000);
+ DueTime.QuadPart = Int32x32To64(1000 - timeElapsed, -10000);
SetWaitableTimer(hTimer, &DueTime, 0, NULL, NULL, FALSE);
dwWaitState = WaitForSingleObject(hTimer, INFINITE);