Skip to content

Commit

Permalink
Disable undo in new debug buffer
Browse files Browse the repository at this point in the history
  • Loading branch information
ahyatt committed Aug 7, 2012
1 parent e553104 commit b5bdb10
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions websocket.el
Expand Up @@ -527,8 +527,11 @@ These are defined as in `websocket-open'."

(defun websocket-get-debug-buffer-create (websocket)
"Get or create the buffer corresponding to WEBSOCKET."
(get-buffer-create (format "*websocket %s debug*"
(websocket-url websocket))))
(let ((buf (get-buffer-create (format "*websocket %s debug*"
(websocket-url websocket)))))
(when (= 0 (buffer-size buf))
(buffer-disable-undo buf))
buf))

(defun websocket-debug (websocket msg &rest args)
"In the WEBSOCKET's debug buffer, send MSG, with format ARGS."
Expand Down

0 comments on commit b5bdb10

Please sign in to comment.