From 43875a7fae6fa7b1621257969b9057fab5a52cfb Mon Sep 17 00:00:00 2001 From: Hugh McMaster Date: Mon, 2 May 2016 12:06:23 +0000 Subject: [PATCH] reg: Output the number of matches when querying the registry recursively. Signed-off-by: Hugh McMaster Signed-off-by: Alexandre Julliard --- po/ar.po | 4 ++++ po/bg.po | 4 ++++ po/ca.po | 4 ++++ po/cs.po | 4 ++++ po/da.po | 4 ++++ po/de.po | 4 ++++ po/el.po | 4 ++++ po/en.po | 4 ++++ po/en_US.po | 4 ++++ po/eo.po | 4 ++++ po/es.po | 4 ++++ po/fa.po | 4 ++++ po/fi.po | 4 ++++ po/fr.po | 4 ++++ po/he.po | 4 ++++ po/hi.po | 4 ++++ po/hr.po | 4 ++++ po/hu.po | 4 ++++ po/it.po | 4 ++++ po/ja.po | 4 ++++ po/ko.po | 4 ++++ po/lt.po | 4 ++++ po/ml.po | 4 ++++ po/nb_NO.po | 4 ++++ po/nl.po | 4 ++++ po/or.po | 4 ++++ po/pa.po | 4 ++++ po/pl.po | 4 ++++ po/pt_BR.po | 4 ++++ po/pt_PT.po | 4 ++++ po/rm.po | 4 ++++ po/ro.po | 4 ++++ po/ru.po | 4 ++++ po/sk.po | 4 ++++ po/sl.po | 4 ++++ po/sr_RS@cyrillic.po | 4 ++++ po/sr_RS@latin.po | 4 ++++ po/sv.po | 4 ++++ po/te.po | 4 ++++ po/th.po | 4 ++++ po/tr.po | 4 ++++ po/uk.po | 4 ++++ po/wa.po | 4 ++++ po/wine.pot | 4 ++++ po/zh_CN.po | 4 ++++ po/zh_TW.po | 4 ++++ programs/reg/reg.c | 7 +++++++ programs/reg/reg.h | 1 + programs/reg/reg.rc | 1 + 49 files changed, 193 insertions(+) diff --git a/po/ar.po b/po/ar.po index 9d8386efc6..4e30d7354c 100644 --- a/po/ar.po +++ b/po/ar.po @@ -11896,6 +11896,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "ال&سجل" diff --git a/po/bg.po b/po/bg.po index b484ddb753..13e6bac636 100644 --- a/po/bg.po +++ b/po/bg.po @@ -11512,6 +11512,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Регистър" diff --git a/po/ca.po b/po/ca.po index 1649010291..e4a5de1471 100644 --- a/po/ca.po +++ b/po/ca.po @@ -11775,6 +11775,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registre" diff --git a/po/cs.po b/po/cs.po index ae7cd2c991..1da05dc61f 100644 --- a/po/cs.po +++ b/po/cs.po @@ -11583,6 +11583,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registr" diff --git a/po/da.po b/po/da.po index 050d43a55a..75dc1b746a 100644 --- a/po/da.po +++ b/po/da.po @@ -11849,6 +11849,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Register" diff --git a/po/de.po b/po/de.po index e23d7ab848..16acac1fdb 100644 --- a/po/de.po +++ b/po/de.po @@ -11753,6 +11753,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registrierung" diff --git a/po/el.po b/po/el.po index 207ff072dd..8416c60b26 100644 --- a/po/el.po +++ b/po/el.po @@ -11298,6 +11298,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/en.po b/po/en.po index 019aecbf07..8c13ef6fed 100644 --- a/po/en.po +++ b/po/en.po @@ -11647,6 +11647,10 @@ msgstr "" "reg: Unable to complete the specified operation. An unexpected error " "occurred.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "Search complete. Number of matches found: %1!d!\n" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registry" diff --git a/po/en_US.po b/po/en_US.po index b3f84c8db7..6b133bbd46 100644 --- a/po/en_US.po +++ b/po/en_US.po @@ -11647,6 +11647,10 @@ msgstr "" "reg: Unable to complete the specified operation. An unexpected error " "occurred.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "Search complete. Number of matches found: %1!d!\n" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registry" diff --git a/po/eo.po b/po/eo.po index ec82e55c60..65bff64078 100644 --- a/po/eo.po +++ b/po/eo.po @@ -11202,6 +11202,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registrejo" diff --git a/po/es.po b/po/es.po index 2a7d81fa78..b4bed8d40f 100644 --- a/po/es.po +++ b/po/es.po @@ -11928,6 +11928,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registro" diff --git a/po/fa.po b/po/fa.po index b5f0bf41bb..23d5f54516 100644 --- a/po/fa.po +++ b/po/fa.po @@ -11292,6 +11292,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/fi.po b/po/fi.po index 2d357ab9ea..2bd5dcc2cf 100644 --- a/po/fi.po +++ b/po/fi.po @@ -11626,6 +11626,10 @@ msgstr "" "reg: Määrätyn toiminnon suorittaminen ei onnistu. Tapahtui odottamaton " "virhe.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Rekisteri" diff --git a/po/fr.po b/po/fr.po index 0f42ced732..68f23b7683 100644 --- a/po/fr.po +++ b/po/fr.po @@ -11787,6 +11787,10 @@ msgstr "" "reg : Impossible d'effectuer l'opération spécifiée. Une erreur inattendue " "est survenue.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registre" diff --git a/po/he.po b/po/he.po index 03bdcfc80d..8d122e128e 100644 --- a/po/he.po +++ b/po/he.po @@ -11673,6 +11673,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&רישום המערכת" diff --git a/po/hi.po b/po/hi.po index 3582f046cf..d8211ccefd 100644 --- a/po/hi.po +++ b/po/hi.po @@ -11099,6 +11099,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/hr.po b/po/hr.po index 18358f31d2..3af5e744ff 100644 --- a/po/hr.po +++ b/po/hr.po @@ -11406,6 +11406,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registar" diff --git a/po/hu.po b/po/hu.po index aca6c5c689..c18b46d7a4 100644 --- a/po/hu.po +++ b/po/hu.po @@ -11843,6 +11843,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Fájl" diff --git a/po/it.po b/po/it.po index 5cdd6397fb..e9cc3a5a68 100644 --- a/po/it.po +++ b/po/it.po @@ -11929,6 +11929,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registro" diff --git a/po/ja.po b/po/ja.po index 92e8a46fb8..335c6240d6 100644 --- a/po/ja.po +++ b/po/ja.po @@ -11629,6 +11629,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "レジストリ(&R)" diff --git a/po/ko.po b/po/ko.po index f189d334a9..f9d6415acb 100644 --- a/po/ko.po +++ b/po/ko.po @@ -11918,6 +11918,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "레지스트리(&R)" diff --git a/po/lt.po b/po/lt.po index 6041789921..5418a2cf6b 100644 --- a/po/lt.po +++ b/po/lt.po @@ -11651,6 +11651,10 @@ msgid "" "occurred.\n" msgstr "reg: Nepavyko užbaigti nurodytos operacijos. Įvyko netikėta klaida.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "R&egistras" diff --git a/po/ml.po b/po/ml.po index 1e3aaa69a3..a789ca3f12 100644 --- a/po/ml.po +++ b/po/ml.po @@ -11099,6 +11099,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/nb_NO.po b/po/nb_NO.po index ec01b3e561..f36e1720b4 100644 --- a/po/nb_NO.po +++ b/po/nb_NO.po @@ -11754,6 +11754,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Register" diff --git a/po/nl.po b/po/nl.po index 3e8c5b2a48..727a048b64 100644 --- a/po/nl.po +++ b/po/nl.po @@ -11895,6 +11895,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registerbestand" diff --git a/po/or.po b/po/or.po index 9241b8dbe0..78528d807c 100644 --- a/po/or.po +++ b/po/or.po @@ -11099,6 +11099,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/pa.po b/po/pa.po index 6f31f289d6..2c6749ad0f 100644 --- a/po/pa.po +++ b/po/pa.po @@ -11099,6 +11099,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/pl.po b/po/pl.po index 9130c1c5c3..a6c80ef274 100644 --- a/po/pl.po +++ b/po/pl.po @@ -11731,6 +11731,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Rejestr" diff --git a/po/pt_BR.po b/po/pt_BR.po index 4c5f2ef8d9..e5b5aaea03 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -11738,6 +11738,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registro" diff --git a/po/pt_PT.po b/po/pt_PT.po index defd1b0bc6..9fde16a469 100644 --- a/po/pt_PT.po +++ b/po/pt_PT.po @@ -11720,6 +11720,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registo" diff --git a/po/rm.po b/po/rm.po index 1902d6c801..eaf48a2fd7 100644 --- a/po/rm.po +++ b/po/rm.po @@ -11177,6 +11177,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/ro.po b/po/ro.po index e955dcef87..15e18609a9 100644 --- a/po/ro.po +++ b/po/ro.po @@ -11939,6 +11939,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registru" diff --git a/po/ru.po b/po/ru.po index b805219b37..f6968af640 100644 --- a/po/ru.po +++ b/po/ru.po @@ -11648,6 +11648,10 @@ msgid "" "occurred.\n" msgstr "reg: не удалось завершить операцию. Произошла непредвиденная ошибка.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Реестр" diff --git a/po/sk.po b/po/sk.po index e99f2b0184..32e9328376 100644 --- a/po/sk.po +++ b/po/sk.po @@ -11371,6 +11371,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Registry" diff --git a/po/sl.po b/po/sl.po index 389d0348c0..b6267992fd 100644 --- a/po/sl.po +++ b/po/sl.po @@ -11872,6 +11872,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Register" diff --git a/po/sr_RS@cyrillic.po b/po/sr_RS@cyrillic.po index 0708d75ea0..1a62a53f12 100644 --- a/po/sr_RS@cyrillic.po +++ b/po/sr_RS@cyrillic.po @@ -11764,6 +11764,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/sr_RS@latin.po b/po/sr_RS@latin.po index b0d3f490d6..07bf6481d6 100644 --- a/po/sr_RS@latin.po +++ b/po/sr_RS@latin.po @@ -11903,6 +11903,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/sv.po b/po/sv.po index 4c2cbb9a4c..987d063119 100644 --- a/po/sv.po +++ b/po/sv.po @@ -11544,6 +11544,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Register" diff --git a/po/te.po b/po/te.po index 492b4c172f..2e6fc7ce44 100644 --- a/po/te.po +++ b/po/te.po @@ -11099,6 +11099,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/th.po b/po/th.po index 27406bc2b6..9efe48870e 100644 --- a/po/th.po +++ b/po/th.po @@ -11330,6 +11330,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/tr.po b/po/tr.po index cba09c19b5..7aa357c863 100644 --- a/po/tr.po +++ b/po/tr.po @@ -11700,6 +11700,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Kayıt" diff --git a/po/uk.po b/po/uk.po index 862c0dc774..603c79a166 100644 --- a/po/uk.po +++ b/po/uk.po @@ -11733,6 +11733,10 @@ msgid "" msgstr "" "reg: неможливо завершити зазначену операцію. Сталася неочікувана помилка.\n" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "&Реєстр" diff --git a/po/wa.po b/po/wa.po index eb4ddd7570..1fcf966ebf 100644 --- a/po/wa.po +++ b/po/wa.po @@ -11238,6 +11238,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/wine.pot b/po/wine.pot index 6e500e6b61..245ec3b0ee 100644 --- a/po/wine.pot +++ b/po/wine.pot @@ -11035,6 +11035,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "" diff --git a/po/zh_CN.po b/po/zh_CN.po index b014d71a9c..3ee5c0b6ca 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -11203,6 +11203,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "注册表(&R)" diff --git a/po/zh_TW.po b/po/zh_TW.po index a13abbdd16..f4eecdc025 100644 --- a/po/zh_TW.po +++ b/po/zh_TW.po @@ -11803,6 +11803,10 @@ msgid "" "occurred.\n" msgstr "" +#: reg.rc:55 +msgid "Search complete. Number of matches found: %1!d!\n" +msgstr "" + #: regedit.rc:34 msgid "&Registry" msgstr "註冊表(&R)" diff --git a/programs/reg/reg.c b/programs/reg/reg.c index c9903ac442..df3b4532fc 100644 --- a/programs/reg/reg.c +++ b/programs/reg/reg.c @@ -655,6 +655,8 @@ static WCHAR *build_subkey_path(WCHAR *path, DWORD path_len, WCHAR *subkey_name, return subkey_path; } +static unsigned int num_values_found = 0; + static int query_value(HKEY key, WCHAR *value_name, WCHAR *path, BOOL recurse) { LONG rc; @@ -689,6 +691,7 @@ static int query_value(HKEY key, WCHAR *value_name, WCHAR *path, BOOL recurse) output_string(fmt, path); output_value(value_name, type, data, data_size); output_string(newlineW); + num_values_found++; } HeapFree(GetProcessHeap(), 0, data); @@ -858,7 +861,11 @@ static int reg_query(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, BOOL } if (value_name || value_empty) + { ret = query_value(key, value_name, key_name, recurse); + if (recurse) + output_message(STRING_MATCHES_FOUND, num_values_found); + } else ret = query_all(key, key_name, recurse); diff --git a/programs/reg/reg.h b/programs/reg/reg.h index dd1e43edc6..102284eaf7 100644 --- a/programs/reg/reg.h +++ b/programs/reg/reg.h @@ -46,3 +46,4 @@ #define STRING_INVALID_STRING 123 #define STRING_VALUEALL_FAILED 124 #define STRING_GENERAL_FAILURE 125 +#define STRING_MATCHES_FOUND 126 diff --git a/programs/reg/reg.rc b/programs/reg/reg.rc index b4888ea9bf..23144a3ecb 100644 --- a/programs/reg/reg.rc +++ b/programs/reg/reg.rc @@ -51,4 +51,5 @@ STRINGTABLE STRING_INVALID_STRING, "reg: The option [/d] must be followed by a valid string\n" STRING_VALUEALL_FAILED, "reg: Unable to delete all registry values in '%1'. An unexpected error occurred.\n" STRING_GENERAL_FAILURE, "reg: Unable to complete the specified operation. An unexpected error occurred.\n" + STRING_MATCHES_FOUND, "Search complete. Number of matches found: %1!d!\n" }