diff options
author | Javier <dev.git@javispedro.com> | 2022-04-03 22:58:39 +0200 |
---|---|---|
committer | Javier <dev.git@javispedro.com> | 2022-04-03 22:58:39 +0200 |
commit | f9b0699da8adb44fd91640180a7b70639a43449b (patch) | |
tree | 81fcbd285a306b85f21086d1c7d37e77af71ed12 /w16mouse.c | |
parent | 71f66c759930ce22f099ad1631f05ddb3e0ccd8a (diff) | |
download | vbados-f9b0699da8adb44fd91640180a7b70639a43449b.tar.gz vbados-f9b0699da8adb44fd91640180a7b70639a43449b.zip |
replace some custom asm utils with watcom intrinsincs
Diffstat (limited to 'w16mouse.c')
-rw-r--r-- | w16mouse.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -124,7 +124,8 @@ BOOL FAR PASCAL LibMain(HINSTANCE hInstance, WORD wDataSegment, uint16_t version = int33_get_driver_version(); // For now we just check for the presence of any int33 driver version - if (version <= 0) { + if (version == 0) { + // No one responded to our request, we can assume no driver // This will cause a "can't load .drv" message from Windows return 0; } @@ -147,9 +148,9 @@ WORD FAR PASCAL Inquire(LPMOUSEINFO lpMouseInfo) VOID FAR PASCAL Enable(LPFN_MOUSEEVENT lpEventProc) { // Store the windows-given callback - cli(); // Write to far pointer may not be atomic, and we could be interrupted mid-write + _disable(); // Write to far pointer may not be atomic, and we could be interrupted mid-write eventproc = lpEventProc; - sti(); + _enable(); if (!enabled) { int33_reset(); |