From c2f93ca5992769a96b77dafa5ae195feba99b6d5 Mon Sep 17 00:00:00 2001 From: ReaP <67383323+Peribunt@users.noreply.github.com> Date: Mon, 6 Feb 2023 11:55:50 +0100 Subject: [PATCH] Possible unwanted result from "VmdtRunCheck" Possible unwanted result from "VmdtRunCheck" procedure. Since RAX is treated as a volatile register(return value), it must be emptied upon entering the procedure --- VmdtStr/VmdtStr/vmdt.asm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/VmdtStr/VmdtStr/vmdt.asm b/VmdtStr/VmdtStr/vmdt.asm index 06a17b3..86c5f17 100644 --- a/VmdtStr/VmdtStr/vmdt.asm +++ b/VmdtStr/VmdtStr/vmdt.asm @@ -1,6 +1,8 @@ .CODE VmdtRunCheck PROC + xor rax, rax + push rsi push rdi @@ -14,7 +16,7 @@ VmdtRunCheck PROC and rsi, rdi cmp rsi, 0 jne finish - mov ax, 1 + mov al, 1 finish: pop rdi @@ -23,4 +25,4 @@ finish: ret VmdtRunCheck ENDP -END \ No newline at end of file +END