From: Po Lu Date: Thu, 26 May 2022 06:27:32 +0000 (+0800) Subject: Use x_get_atom_name for some more things X-Git-Tag: emacs-29.0.90~1910^2~420 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c67c7ab53c0fe4ff03c722c9bac44fcea6ad0699;p=emacs.git Use x_get_atom_name for some more things * src/xterm.c (x_dnd_send_unsupported_drop, x_dnd_send_drop): Use x_get_atom_name instead of XGetAtomName. --- diff --git a/src/xterm.c b/src/xterm.c index d518ce331ae..cde98b43b45 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -3244,13 +3244,13 @@ x_dnd_send_unsupported_drop (struct x_display_info *dpyinfo, Window target_windo XFree (atom_names[i - 1]); } - name = XGetAtomName (dpyinfo->display, - x_dnd_wanted_action); + name = x_get_atom_name (dpyinfo, x_dnd_wanted_action, + false); if (name) { arg = intern (name); - XFree (name); + xfree (name); } else arg = Qnil; @@ -3810,12 +3810,12 @@ x_dnd_send_drop (struct frame *f, Window target, Time timestamp, lval = Qnil; atom_names = alloca (x_dnd_n_targets * sizeof *atom_names); - name = XGetAtomName (dpyinfo->display, x_dnd_wanted_action); + name = x_get_atom_name (dpyinfo, x_dnd_wanted_action, false); if (!XGetAtomNames (dpyinfo->display, x_dnd_targets, x_dnd_n_targets, atom_names)) { - XFree (name); + xfree (name); return false; } @@ -3833,7 +3833,7 @@ x_dnd_send_drop (struct frame *f, Window target, Time timestamp, XSETINT (ie.x, win_x); XSETINT (ie.y, win_y); - XFree (name); + xfree (name); kbd_buffer_store_event (&ie); return false;