Commit 544f93c4 authored by Philippe Brochard's avatar Philippe Brochard
Browse files

Add some necessary ensure-printable protection

parent cc7b5ea9
......@@ -239,7 +239,7 @@
(defgeneric child-name (child))
(defmethod child-name ((child xlib:window))
(xlib:wm-name child))
(ensure-printable (xlib:wm-name child)))
(defmethod child-name ((child frame))
(frame-name child))
......@@ -268,12 +268,14 @@
(defgeneric child-fullname (child))
(defmethod child-fullname ((child xlib:window))
(format nil "~A (~A)" (or (xlib:wm-name child) "?") (or (xlib:get-wm-class child) "?")))
(ensure-printable
(format nil "~A (~A)" (or (xlib:wm-name child) "?") (or (xlib:get-wm-class child) "?"))))
(defmethod child-fullname ((child frame))
(aif (frame-name child)
(format nil "~A (Frame ~A)" it (frame-number child))
(format nil "Frame ~A" (frame-number child))))
(ensure-printable
(aif (frame-name child)
(format nil "~A (Frame ~A)" it (frame-number child))
(format nil "Frame ~A" (frame-number child)))))
(defmethod child-fullname (child)
(declare (ignore child))
......
......@@ -41,12 +41,13 @@
(defun add-char-in-query-string (char)
(setf *query-string* (concatenate 'string
(when (<= *query-pos* (length *query-string*))
(subseq *query-string* 0 *query-pos*))
(string char)
(when (< *query-pos* (length *query-string*))
(subseq *query-string* *query-pos*))))
(setf *query-string* (ensure-printable
(concatenate 'string
(when (<= *query-pos* (length *query-string*))
(subseq *query-string* 0 *query-pos*))
(string char)
(when (< *query-pos* (length *query-string*))
(subseq *query-string* *query-pos*)))))
(incf *query-pos*))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment