From 927e954a2cda16d7b6cf8486869a300f4f422db8 Mon Sep 17 00:00:00 2001 From: "Clarence \"Sparr\" Risher" Date: Thu, 9 Nov 2023 06:47:50 -0500 Subject: [PATCH] Replace bad arithmetic in tnt_select limit param example --- doc/connector/c.rst | 2 +- locale/ru/LC_MESSAGES/book/connectors.po | 4 ++-- locale/ru/LC_MESSAGES/book/connectors/c.po | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/doc/connector/c.rst b/doc/connector/c.rst index 2000da4068..74765d1966 100644 --- a/doc/connector/c.rst +++ b/doc/connector/c.rst @@ -249,7 +249,7 @@ To display the results, the program uses functions in the } struct tnt_stream *tuple = tnt_object(NULL); tnt_object_format(tuple, "[%d]", 99999); /* tuple = search key */ - tnt_select(tnt, 999, 0, (2^32) - 1, 0, 0, tuple); + tnt_select(tnt, 999, 0, UINT32_MAX, 0, 0, tuple); tnt_flush(tnt); struct tnt_reply reply; tnt_reply_init(&reply); tnt->read_reply(tnt, &reply); diff --git a/locale/ru/LC_MESSAGES/book/connectors.po b/locale/ru/LC_MESSAGES/book/connectors.po index 6a2e4f6cf0..7f8d1cb156 100644 --- a/locale/ru/LC_MESSAGES/book/connectors.po +++ b/locale/ru/LC_MESSAGES/book/connectors.po @@ -1982,7 +1982,7 @@ msgid "" " }\n" " struct tnt_stream *tuple = tnt_object(NULL);\n" " tnt_object_format(tuple, \"[%d]\", 99999); /* tuple = search key */\n" -" tnt_select(tnt, 999, 0, (2^32) - 1, 0, 0, tuple);\n" +" tnt_select(tnt, 999, 0, UINT32_MAX, 0, 0, tuple);\n" " tnt_flush(tnt);\n" " struct tnt_reply reply; tnt_reply_init(&reply);\n" " tnt->read_reply(tnt, &reply);\n" @@ -2047,7 +2047,7 @@ msgstr "" " }\n" " struct tnt_stream *tuple = tnt_object(NULL);\n" " tnt_object_format(tuple, \"[%d]\", 99999); /* кортеж tuple = ключ для поиска */\n" -" tnt_select(tnt, 999, 0, (2^32) - 1, 0, 0, tuple);\n" +" tnt_select(tnt, 999, 0, UINT32_MAX, 0, 0, tuple);\n" " tnt_flush(tnt);\n" " struct tnt_reply reply; tnt_reply_init(&reply);\n" " tnt->read_reply(tnt, &reply);\n" diff --git a/locale/ru/LC_MESSAGES/book/connectors/c.po b/locale/ru/LC_MESSAGES/book/connectors/c.po index d6b3189438..d0eb8f4800 100644 --- a/locale/ru/LC_MESSAGES/book/connectors/c.po +++ b/locale/ru/LC_MESSAGES/book/connectors/c.po @@ -374,7 +374,7 @@ msgid "" " }\n" " struct tnt_stream *tuple = tnt_object(NULL);\n" " tnt_object_format(tuple, \"[%d]\", 99999); /* tuple = search key */\n" -" tnt_select(tnt, 999, 0, (2^32) - 1, 0, 0, tuple);\n" +" tnt_select(tnt, 999, 0, UINT32_MAX, 0, 0, tuple);\n" " tnt_flush(tnt);\n" " struct tnt_reply reply; tnt_reply_init(&reply);\n" " tnt->read_reply(tnt, &reply);\n" @@ -439,7 +439,7 @@ msgstr "" " }\n" " struct tnt_stream *tuple = tnt_object(NULL);\n" " tnt_object_format(tuple, \"[%d]\", 99999); /* кортеж tuple = ключ для поиска */\n" -" tnt_select(tnt, 999, 0, (2^32) - 1, 0, 0, tuple);\n" +" tnt_select(tnt, 999, 0, UINT32_MAX, 0, 0, tuple);\n" " tnt_flush(tnt);\n" " struct tnt_reply reply; tnt_reply_init(&reply);\n" " tnt->read_reply(tnt, &reply);\n"