Skip to content

Commit cd2e648

Browse files
committed
optimize: don't bother decoding output
Apparently, the JSON parser handles decoding internally so there's no need to double-decode. This won't make a huge difference, but reduce some CPU usage.
1 parent d9591a9 commit cd2e648

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

i3bar.el

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,13 +211,15 @@ If the process has exited, this function stores the exit STATUS in
211211
(let ((default-directory user-emacs-directory)
212212
(proc-buffer (get-buffer-create " *i3status process*")))
213213
(with-current-buffer proc-buffer
214+
(set-buffer-multibyte nil)
214215
(erase-buffer)
215216
(add-hook 'after-change-functions 'i3bar--process-after-change nil t))
216217
(setq i3bar--process (make-process
217218
:name "i3bar"
218219
:buffer proc-buffer
219220
:stderr " *i3status stderr*"
220221
:command (ensure-list i3bar-command)
222+
:coding 'binary
221223
:connection-type 'pipe
222224
:noquery t
223225
:sentinel #'i3bar--process-sentinel)))

0 commit comments

Comments
 (0)