diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2023-04-05 20:56:48 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2023-04-05 20:56:48 +0200 |
commit | 87216279cae1d3b8a7fb13031dfd00ab0452fd35 (patch) | |
tree | f9212b32d4c0e911205dbfb61914ddf1bca72a9a | |
parent | b6a59be3172cb389e9170b1d60346fa7e8b5a534 (diff) | |
download | weechat-87216279cae1d3b8a7fb13031dfd00ab0452fd35.zip |
irc: display a warning if CTCP name in option `irc.ctcp.*` is not lower case
-rw-r--r-- | po/cs.po | 8 | ||||
-rw-r--r-- | po/de.po | 8 | ||||
-rw-r--r-- | po/es.po | 8 | ||||
-rw-r--r-- | po/fr.po | 12 | ||||
-rw-r--r-- | po/hu.po | 8 | ||||
-rw-r--r-- | po/it.po | 8 | ||||
-rw-r--r-- | po/ja.po | 8 | ||||
-rw-r--r-- | po/pl.po | 8 | ||||
-rw-r--r-- | po/pt.po | 8 | ||||
-rw-r--r-- | po/pt_BR.po | 8 | ||||
-rw-r--r-- | po/ru.po | 8 | ||||
-rw-r--r-- | po/sr.po | 8 | ||||
-rw-r--r-- | po/tr.po | 8 | ||||
-rw-r--r-- | po/weechat.pot | 8 | ||||
-rw-r--r-- | src/plugins/irc/irc-config.c | 18 |
15 files changed, 117 insertions, 17 deletions
@@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8488,6 +8488,12 @@ msgstr "buffer použitý pro zobrazení zprávy obdržené od IRC serveru" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: chyba vytváření \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -26,7 +26,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-04-01 22:43+0200\n" "Last-Translator: Nils Görs <weechatter@arcor.de>\n" "Language-Team: German - Germany <weechatter@arcor.de>\n" @@ -10553,6 +10553,12 @@ msgstr "" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: Fehler beim Erstellen von \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Santiago Forero <santiago@forero.xyz>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -9151,6 +9151,12 @@ msgstr "buffer donde mostrar los mensajes recibidos desde el servidor IRC" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: error al crear \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -21,8 +21,8 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" -"PO-Revision-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" +"PO-Revision-Date: 2023-04-05 20:55+0200\n" "Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" "Language: fr\n" @@ -10367,6 +10367,14 @@ msgstr "tampon utilisé pour afficher le message reçu du serveur IRC" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s : erreur de création \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" +"%s%s : attention : le nom CTCP \"%s\" doit être en minuscules, l'option " +"\"irc.ctcp.%s\" ne fonctionnera pas" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2022-10-15 22:51+0200\n" "Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8016,6 +8016,12 @@ msgstr "" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s nincs elég memória az információs pult üzenethez\n" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8858,6 +8858,12 @@ msgstr "buffer usato per visualizzare i messaggi ricevuti dal server IRC" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: errore nella creazione \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n" "Language-Team: Japanese <https://github.com/l/weechat/tree/master/" @@ -9967,6 +9967,12 @@ msgstr "IRC サーバから受け取ったメッセージを表示するバッ msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: 作成中のエラー \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-27 22:02+0200\n" "Last-Translator: Krzysztof Korościk <soltys@soltys.info>\n" "Language-Team: Polish <kde-i18n-doc@kde.org>\n" @@ -10785,6 +10785,12 @@ msgstr "bufor używany do wyświetlania wiadomości otrzymanych od serwera IRC" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: błąd podczas tworzenia \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n" "Language-Team: Portuguese <>\n" @@ -9739,6 +9739,12 @@ msgstr "buffer usado para mostrar mensagens recebidas do servidor IRC" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: erro ao criar \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " diff --git a/po/pt_BR.po b/po/pt_BR.po index e7c1b0798..90bc42e28 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Érico Nogueira <ericonr@disroot.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8523,6 +8523,12 @@ msgstr "buffer utilizado para exibir mensagem recebida do servidor IRC" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: erro ao criar \"%s\" => \"%s\"" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -8046,6 +8046,12 @@ msgstr "" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s недостаточно памяти для сообщения в строке информации\n" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-27 22:15+0200\n" "Last-Translator: Ivan Pešić <ivan.pesic@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -10485,6 +10485,12 @@ msgstr "бафер који се користи за приказ поруке msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: грешка при креирању „%s” => „%s”" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2023-03-25 21:13+0100\n" "Last-Translator: Emir SARI <emir_sari@icloud.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -10750,6 +10750,12 @@ msgstr "" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "%s%s: \"%s\" => \"%s\" oluşturulurken hata" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " diff --git a/po/weechat.pot b/po/weechat.pot index bba8763f2..55b8d2f35 100644 --- a/po/weechat.pot +++ b/po/weechat.pot @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-04-01 11:12+0200\n" +"POT-Creation-Date: 2023-04-05 20:55+0200\n" "PO-Revision-Date: 2014-08-16 10:27+0200\n" "Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -7208,6 +7208,12 @@ msgstr "" msgid "%s%s: error creating \"%s\" => \"%s\"" msgstr "" +#, c-format +msgid "" +"%s%s: warning: the CTCP name \"%s\" must be lower case, the option \"irc." +"ctcp.%s\" will not work" +msgstr "" + msgid "" "format for CTCP reply or empty string for blocking CTCP (no reply), " "following variables are replaced: $version (WeeChat version), $compilation " diff --git a/src/plugins/irc/irc-config.c b/src/plugins/irc/irc-config.c index bc243b15f..aa6d4677c 100644 --- a/src/plugins/irc/irc-config.c +++ b/src/plugins/irc/irc-config.c @@ -1471,9 +1471,9 @@ irc_config_ctcp_create_option (const void *pointer, void *data, { struct t_config_option *ptr_option; int rc; - const char *default_value; + const char *default_value, *pos_name; + char *name_lower; static char empty_value[1] = { '\0' }; - const char *pos_name; /* make C compiler happy */ (void) pointer; @@ -1506,6 +1506,20 @@ irc_config_ctcp_create_option (const void *pointer, void *data, if (!default_value) default_value = empty_value; + name_lower = weechat_string_tolower (pos_name); + if (name_lower && (strcmp (pos_name, name_lower) != 0)) + { + weechat_printf ( + NULL, + _("%s%s: warning: the CTCP name \"%s\" must be " + "lower case, the option \"irc.ctcp.%s\" will " + "not work"), + weechat_prefix ("error"), IRC_PLUGIN_NAME, pos_name, + option_name); + } + if (name_lower) + free (name_lower); + ptr_option = weechat_config_new_option ( config_file, section, option_name, "string", |