Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nanopb/nanopb.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetteri Aimonen <jpa@git.mail.kapsi.fi>2020-06-24 13:20:18 +0300
committerPetteri Aimonen <jpa@git.mail.kapsi.fi>2020-06-24 13:20:18 +0300
commit0c3a71cca3a9e251a1d114623b8b0161dcbfe096 (patch)
tree365328e692a300855bdf95efb88932c8425b9d5c /pb_common.h
parent48e875de4668e561b621f1606d98e69a71ccfc05 (diff)
pb_decode: performance optimizations for extension field handling
Diffstat (limited to 'pb_common.h')
-rw-r--r--pb_common.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/pb_common.h b/pb_common.h
index 47fa2c9..58aa90f 100644
--- a/pb_common.h
+++ b/pb_common.h
@@ -32,6 +32,10 @@ bool pb_field_iter_next(pb_field_iter_t *iter);
* Returns false if no such field exists. */
bool pb_field_iter_find(pb_field_iter_t *iter, uint32_t tag);
+/* Find a field with type PB_LTYPE_EXTENSION, or return false if not found.
+ * There can be only one extension range field per message. */
+bool pb_field_iter_find_extension(pb_field_iter_t *iter);
+
#ifdef PB_VALIDATE_UTF8
/* Validate UTF-8 text string */
bool pb_validate_utf8(const char *s);