summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2023-04-05 20:56:48 +0200
committerSébastien Helleu <flashcode@flashtux.org>2023-04-05 20:56:48 +0200
commit87216279cae1d3b8a7fb13031dfd00ab0452fd35 (patch)
treef9212b32d4c0e911205dbfb61914ddf1bca72a9a
parentb6a59be3172cb389e9170b1d60346fa7e8b5a534 (diff)
downloadweechat-87216279cae1d3b8a7fb13031dfd00ab0452fd35.zip
irc: display a warning if CTCP name in option `irc.ctcp.*` is not lower case
-rw-r--r--po/cs.po8
-rw-r--r--po/de.po8
-rw-r--r--po/es.po8
-rw-r--r--po/fr.po12
-rw-r--r--po/hu.po8
-rw-r--r--po/it.po8
-rw-r--r--po/ja.po8
-rw-r--r--po/pl.po8
-rw-r--r--po/pt.po8
-rw-r--r--po/pt_BR.po8
-rw-r--r--po/ru.po8
-rw-r--r--po/sr.po8
-rw-r--r--po/tr.po8
-rw-r--r--po/weechat.pot8
-rw-r--r--src/plugins/irc/irc-config.c18
15 files changed, 117 insertions, 17 deletions
diff --git a/po/cs.po b/po/cs.po
index fe5590b86..20802f512 100644
--- a/po/cs.po
+++ b/po/cs.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: 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 "
diff --git a/po/de.po b/po/de.po
index 314236087..3c9ba2126 100644
--- a/po/de.po
+++ b/po/de.po
@@ -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 "
diff --git a/po/es.po b/po/es.po
index 45eebe262..d4d98aac9 100644
--- a/po/es.po
+++ b/po/es.po
@@ -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 "
diff --git a/po/fr.po b/po/fr.po
index 43d0905f1..b117a4105 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -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 "
diff --git a/po/hu.po b/po/hu.po
index a41a0e5e3..3354129bc 100644
--- a/po/hu.po
+++ b/po/hu.po
@@ -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 "
diff --git a/po/it.po b/po/it.po
index 2cd4256b7..0b9762ddf 100644
--- a/po/it.po
+++ b/po/it.po
@@ -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 "
diff --git a/po/ja.po b/po/ja.po
index 0fa84c3c0..428f6cb3b 100644
--- a/po/ja.po
+++ b/po/ja.po
@@ -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 "
diff --git a/po/pl.po b/po/pl.po
index 1795afa77..87982393d 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -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 "
diff --git a/po/pt.po b/po/pt.po
index 828348b93..14d0da8dd 100644
--- a/po/pt.po
+++ b/po/pt.po
@@ -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 "
diff --git a/po/ru.po b/po/ru.po
index 5863c17bd..3a1f59a84 100644
--- a/po/ru.po
+++ b/po/ru.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: 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 "
diff --git a/po/sr.po b/po/sr.po
index 14ff4c641..54d8babb8 100644
--- a/po/sr.po
+++ b/po/sr.po
@@ -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 "
diff --git a/po/tr.po b/po/tr.po
index df1f83a86..4339c1028 100644
--- a/po/tr.po
+++ b/po/tr.po
@@ -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",