Skip to content

Commit

Permalink
lib: only reset global errno if needed (for direct API)
Browse files Browse the repository at this point in the history
  • Loading branch information
pablodelara authored and mdcornu committed Dec 12, 2022
1 parent fe86952 commit 9f5adae
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/include/error.inc
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,10 @@ SET_ERRNO_TYPES \
;; Reset global imb_errno to 0
%macro IMB_ERR_CHECK_RESET 0

cmp dword [rel imb_errno], 0
jz %%do_not_reset
mov dword [rel imb_errno], 0
%%do_not_reset:
%endmacro

;; Set GP reg and global imb_errno to 0
Expand Down

0 comments on commit 9f5adae

Please sign in to comment.