emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 34e257f: Use mint_ptr in w32notify.c


From: Eli Zaretskii
Subject: [Emacs-diffs] master 34e257f: Use mint_ptr in w32notify.c
Date: Sat, 16 Jun 2018 07:17:51 -0400 (EDT)

branch: master
commit 34e257f83a22093cc8dd7a6cd8a4707123f5af77
Author: Eli Zaretskii <address@hidden>
Commit: Eli Zaretskii <address@hidden>

    Use mint_ptr in w32notify.c
    
    * src/w32notify.c (Fw32notify_add_watch, Fw32notify_rm_watch)
    (Fw32notify_valid_p, w32_get_watch_object): Use make_mint_ptr and
    xmint_pointer.
---
 src/w32notify.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/w32notify.c b/src/w32notify.c
index 5c1d212..67385b8 100644
--- a/src/w32notify.c
+++ b/src/w32notify.c
@@ -622,7 +622,7 @@ generate notifications correctly, though.  */)
        report_file_notify_error ("Cannot watch file", Fcons (file, Qnil));
     }
   /* Store watch object in watch list. */
-  watch_descriptor = make_pointer_integer (dirwatch);
+  watch_descriptor = make_mint_ptr (dirwatch);
   watch_object = Fcons (watch_descriptor, callback);
   watch_list = Fcons (watch_object, watch_list);
 
@@ -647,7 +647,7 @@ WATCH-DESCRIPTOR should be an object returned by 
`w32notify-add-watch'.  */)
   if (!NILP (watch_object))
     {
       watch_list = Fdelete (watch_object, watch_list);
-      dirwatch = (struct notification *)XINTPTR (watch_descriptor);
+      dirwatch = (struct notification *)xmint_pointer (watch_descriptor);
       if (w32_valid_pointer_p (dirwatch, sizeof(struct notification)))
        status = remove_watch (dirwatch);
     }
@@ -662,7 +662,7 @@ WATCH-DESCRIPTOR should be an object returned by 
`w32notify-add-watch'.  */)
 Lisp_Object
 w32_get_watch_object (void *desc)
 {
-  Lisp_Object descriptor = make_pointer_integer (desc);
+  Lisp_Object descriptor = make_mint_ptr (desc);
 
   /* This is called from the input queue handling code, inside a
      critical section, so we cannot possibly quit if watch_list is not
@@ -685,7 +685,7 @@ watch by calling `w32notify-rm-watch' also makes it 
invalid.  */)
   if (!NILP (watch_object))
     {
       struct notification *dirwatch =
-       (struct notification *)XINTPTR (watch_descriptor);
+       (struct notification *)xmint_pointer (watch_descriptor);
       if (w32_valid_pointer_p (dirwatch, sizeof(struct notification))
          && dirwatch->dir != NULL)
        return Qt;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]