changeset 28:40626191b1fa

change utf-8 to binary for set-process-coding-system coding
author gongo
date Sat, 10 Nov 2007 22:54:51 +0900
parents 7134bc86f50d
children ba1829a0c788
files ChangeLog redit-client-sm.el redit-client-sm.elc translate.el
diffstat 4 files changed, 12 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Nov 10 21:33:31 2007 +0900
+++ b/ChangeLog	Sat Nov 10 22:54:51 2007 +0900
@@ -1,5 +1,10 @@
 2007-11-10  Wataru MIYAGUNI  <gongo@cr.ie.u-ryukyu.ac.jp>
 
+	* redit-client-sm.el: set-process-coding-system
+	送受信するパケットは binary の方が良いと指摘。
+	そう言われれば確かにそうでした。pack/unpackの意味なす
+	ってことで 'utf-8 から 'binary に変更しました。
+
 	* redit-client-sm.el: process-send-string 関連
 	process-send-string で、以前までは、送るコマンドを
 
--- a/redit-client-sm.el	Sat Nov 10 21:33:31 2007 +0900
+++ b/redit-client-sm.el	Sat Nov 10 22:54:51 2007 +0900
@@ -175,8 +175,10 @@
   ;; called when the process receive packet
   (set-process-filter redit-client-process 'redit-client-process-filter)
 
-  ;; Code of the process input/output buffer is rep-string-encoding
-  (set-process-coding-system redit-client-process rep-string-encoding rep-string-encoding)
+  ;; //Code of the process input/output buffer is rep-string-encoding
+  ;; //(set-process-coding-system redit-client-process rep-string-encoding rep-string-encoding)
+  ;; 送受信するデータは utf-8 じゃなくて バイナリで貰わないとずれる?可能性があるので
+  (set-process-coding-system redit-client-process 'binary 'binary)
 
   ;; プロセスが生きてるとき、 emacs を終了しようとすると
   ;; 「processがうんたらで、本当に切ってもいいの y/n」
Binary file redit-client-sm.elc has changed
--- a/translate.el	Sat Nov 10 21:33:31 2007 +0900
+++ b/translate.el	Sat Nov 10 22:54:51 2007 +0900
@@ -44,7 +44,7 @@
       (prog1
 	  (pop (Queue-front queue))
 	(unless (Queue-front queue)
-	  ;; queue become empty
+	  ;; queue is empty
 	  (setf (Queue-rear queue) nil)))))
 
 (defun redit-pack-int-loop (num count)
@@ -82,6 +82,8 @@
 ;; @param rcmd REPcommand queue of Remote Host
 ;; @param lcmd REPcommand queue of Local Host
 ;;  
+;;   by kent
+;;
 ;;   比較時に行番号が重なったときの処理は以下の表。
 ;;   なるべくテキストが残るようにしている。
 ;;   0   -- なにもしない