mirror of
https://github.com/weechat/weechat.git
synced 2026-07-10 03:33:12 +02:00
api: change type of arguments status/gnutls_rc/sock in hook_connect() callback from string to integer (in scripts)
This commit is contained in:
@@ -8808,7 +8808,8 @@ hook3 = weechat.hook_process_hashtable("sh",
|
||||
|
||||
==== hook_connect
|
||||
|
||||
_WeeChat バージョン 1.5 で更新。_
|
||||
// TRANSLATION MISSING
|
||||
_Updated in 1.5, 2.0._
|
||||
|
||||
接続をフックする (リモートホストへのバックグラウンド接続)。
|
||||
|
||||
@@ -8891,6 +8892,13 @@ struct t_hook *weechat_hook_connect (const char *proxy,
|
||||
|
||||
* 新しいフックへのポインタ、エラーが起きた場合は NULL
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[IMPORTANT]
|
||||
In scripts, with WeeChat ≥ 2.0, the callback arguments _status_, _gnutls_rc_
|
||||
and _sock_ are integers (with WeeChat ≤ 1.9, they were strings). +
|
||||
To be compatible with all versions, it is recommended to convert the argument
|
||||
to integer before using it, for example in Python: `int(sock)`.
|
||||
|
||||
C 言語での使用例:
|
||||
|
||||
[source,C]
|
||||
|
||||
Reference in New Issue
Block a user