Emacs“进程过滤器中的错误:menu-bar-update-yank-menu:错误的类型参数:stringp,nil”

时间:2012-08-03 12:24:44

标签: emacs elisp

我在https://github.com/coordinate/bingapiel维护了一个elisp项目。

用于在emacs中翻译bing api。

有些用户抱怨这个错误:

error in process filter: menu-bar-update-yank-menu: Wrong type argument: stringp, nil
error in process filter: Wrong type argument: stringp, nil

但我无法在计算机上重现错误。

所以我来这里寻求帮助。有没有人遇到过这个错误。有谁知道“menu-bar-update-yank-menu:错误的类型参数:stringp,nil”的含义。欢迎提出任何建议。

1 个答案:

答案 0 :(得分:1)

可能是由钩子引起的,而钩子没有按预期进给 例如,缓冲区在课程间被杀死

第128-131行bing-translate.el对我来说很奇怪

    (with-current-buffer buf
      (let* ((xmldata (decode-coding-string (buffer-string) 'utf-8))
             (result nil))
        (kill-buffer (current-buffer))
        (when (equal "expired" (bingapi-check-accesstoken xmldata))
          ;; get secend time
          (setq buf (url-retrieve-synchronously
                     (bingtranslate-make-url
                      "GetLanguagesForTranslate?" nil)))
          (if buf

;;;;

即。 current-buf“buf”被杀, 稍后再次设置“何时” 但只是“当”

in not,如果运行为空(?)

正如第一眼看到的那样......