diff --git a/src/string.asm b/src/string.asm index 6f27b48..b5ba02a 100644 --- a/src/string.asm +++ b/src/string.asm @@ -118,7 +118,7 @@ strclr: ; rdx* Length of str1 ; r8* Backup for rdi strcmp: - mov rax, -1 + xor rax, rax cmp byte [rdi], EOS je .equal cmp byte [rsi], EOS @@ -139,7 +139,7 @@ strcmp: .equal: cmp byte [rsi], EOS jne .quit - mov rax, -1 + xor rax, rax .quit: ret