summaryrefslogtreecommitdiff
path: root/src/backend/commands/extension.c
diff options
context:
space:
mode:
authorHeikki Linnakangas2021-01-28 12:40:07 +0000
committerHeikki Linnakangas2021-01-28 12:40:07 +0000
commitb80e10638e36b9d2f0b39170c613837af2ca2aac (patch)
treee5219f9dd452a60abd1b583b760cb919f0bd4ba0 /src/backend/commands/extension.c
parenta3367aa3c4552170004c92369681730d85e384c6 (diff)
Add mbverifystr() functions specific to each encoding.
This makes pg_verify_mbstr() function faster, by allowing more efficient encoding-specific implementations. All the implementations included in this commit are pretty naive, they just call the same encoding-specific verifychar functions that were used previously, but that already gives a performance boost because the tight character-at-a-time loop is simpler. Reviewed-by: John Naylor Discussion: https://www.postgresql.org/message-id/[email protected]
Diffstat (limited to 'src/backend/commands/extension.c')
-rw-r--r--src/backend/commands/extension.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/commands/extension.c b/src/backend/commands/extension.c
index bac7a9e9b9a..19db329fe6f 100644
--- a/src/backend/commands/extension.c
+++ b/src/backend/commands/extension.c
@@ -682,7 +682,7 @@ read_extension_script_file(const ExtensionControlFile *control,
src_encoding = control->encoding;
/* make sure that source string is valid in the expected encoding */
- pg_verify_mbstr_len(src_encoding, src_str, len, false);
+ (void) pg_verify_mbstr(src_encoding, src_str, len, false);
/*
* Convert the encoding to the database encoding. read_whole_file