diff --git a/client/import_util.h b/client/import_util.h index 0096dd354fb..27e4decc77f 100644 --- a/client/import_util.h +++ b/client/import_util.h @@ -29,7 +29,7 @@ enum class KeyOrConstraintType }; /** - * Struct representing a table keyor constraint definition + * Struct representing a table key or constraint definition */ struct KeyDefinition { diff --git a/client/mysql.cc b/client/mysql.cc index 727d966fa65..6acc5d73f6b 100644 --- a/client/mysql.cc +++ b/client/mysql.cc @@ -1475,7 +1475,7 @@ sig_handler mysql_end(int sig) User, password, and database are UTF8 encoded, prior to the function, this needs to be fixed, in case they contain non-ASCIIs. - Mostly a workaround, to allow existng users with non-ASCII password + Mostly a workaround, to allow existing users with non-ASCII password to survive upgrade without losing connectivity. */ static void maybe_convert_charset(const char **user, const char **password, @@ -2415,7 +2415,7 @@ static COMMANDS *find_command(char cmd_char) /* In binary-mode, we disallow all client commands except '\C', - DELIMITER (see long comand finding find_command(char *)) + DELIMITER (see long command finding find_command(char *)) and '\-' (sandbox, see following comment). */ if (real_binary_mode) diff --git a/client/mysqlcheck.c b/client/mysqlcheck.c index 046d24c6c59..c84fb50ef58 100644 --- a/client/mysqlcheck.c +++ b/client/mysqlcheck.c @@ -1080,9 +1080,9 @@ static void __attribute__((noinline)) print_result() If the error message includes REPAIR TABLE, we assume it means we have to run REPAIR on it. In this case we write a nicer message than "Please do "REPAIR TABLE""... - If the message inclused ALTER TABLE then there is something wrong + If the message includes ALTER TABLE then there is something wrong with the table definition and we have to run ALTER TABLE to fix it. - Write also a nice error message for this csae. + Write also a nice error message for this case. */ if (!strcmp(row[2],"error") && strstr(row[3],"REPAIR ")) { diff --git a/client/mysqldump.cc b/client/mysqldump.cc index 51fb48d69e5..4c05e6f81f4 100644 --- a/client/mysqldump.cc +++ b/client/mysqldump.cc @@ -4269,7 +4269,7 @@ static void dump_table(const char *table, const char *db, const uchar *hash_key, /* Check --skip-events flag: it is not enough to skip creation of events - discarding SHOW CREATE EVENT statements generation. The myslq.event + discarding SHOW CREATE EVENT statements generation. The mysql.event table data should be skipped too. */ if (!opt_events && !cmp_database(db, "mysql") && diff --git a/client/mysqlimport.cc b/client/mysqlimport.cc index ab1bf798d41..01259e95ef8 100644 --- a/client/mysqlimport.cc +++ b/client/mysqlimport.cc @@ -785,7 +785,7 @@ int table_load_params::load_data(MYSQL *mysql) if (exec_sql(mysql, "SET TIME_ZONE=@save_tz;")) DBUG_RETURN(1); } - /* Restore constrains and triggers */ + /* Restore constraints and triggers */ for (const auto &create_trigger_def : triggers) { if (exec_sql(mysql, create_trigger_def)) diff --git a/client/mysqltest.cc b/client/mysqltest.cc index de669640511..d84e4faf47d 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -8625,7 +8625,7 @@ void handle_no_error(struct st_command *command) SYNOPSIS read_stmt_results - stmt - prepare statemet + stmt - prepare statement mysql - mysql handle command - current command pointer ds - output buffer where to store result form query @@ -9534,7 +9534,7 @@ void run_query(struct st_connection *cn, struct st_command *command, int flags) rs_output= &rs_cmp_result; } else - rs_output= &ds_res; // will be shown to colsole + rs_output= &ds_res; // will be shown to console /* Log the query into the output buffer diff --git a/extra/innochecksum.cc b/extra/innochecksum.cc index 8d33ae3d63e..864a576bd09 100644 --- a/extra/innochecksum.cc +++ b/extra/innochecksum.cc @@ -382,7 +382,7 @@ open_file( @param [in,out] buf read the file in buffer @param [in] partial_page_read enable when to read the remaining buffer for first page. - @param [in] physical_page_size Physical/Commpressed page size. + @param [in] physical_page_size Physical/Compressed page size. @param [in,out] fil_in file pointer created for the tablespace. @retval no. of bytes read. @@ -590,7 +590,7 @@ Rewrite the checksum for the page. @retval true : do rewrite @retval false : skip the rewrite as checksum stored match with - calculated or page is doublwrite buffer. + calculated or page is doublewrite buffer. */ static bool update_checksum(byte* page, uint32_t flags) { @@ -1875,7 +1875,7 @@ first_non_zero: } if (!read_from_stdin) { - /* flcose() will flush the data and release the lock if + /* fclose() will flush the data and release the lock if any acquired. */ fclose(fil_in); } diff --git a/extra/mariabackup/aria_backup_client.cc b/extra/mariabackup/aria_backup_client.cc index 25468148fe4..700a62dc4eb 100644 --- a/extra/mariabackup/aria_backup_client.cc +++ b/extra/mariabackup/aria_backup_client.cc @@ -88,7 +88,7 @@ public: Skip all existing log files and find the greatest missing log file. @param datadir - Search files in this directory - @param start - Start searching from this log number and go downto 1. + @param start - Start searching from this log number and go down to 1. @param kind - true - search for an existing file false - search for a missing file. @returns - [1..start] - the greatest found log file diff --git a/extra/mariabackup/backup_copy.cc b/extra/mariabackup/backup_copy.cc index 79b9223f603..311688b6d9b 100644 --- a/extra/mariabackup/backup_copy.cc +++ b/extra/mariabackup/backup_copy.cc @@ -147,7 +147,7 @@ struct datadir_thread_ctxt_t { }; /************************************************************************ -Retirn true if character if file separator */ +Return true if character is file separator */ bool is_path_separator(char c) { @@ -1413,7 +1413,7 @@ bool backup_finish(ds_ctxt *ds_data) /* Drop all empty database directories in the base backup - that do not exists in the icremental backup. + that do not exist in the incremental backup. This effectively re-plays all DROP DATABASE statements happened in between base backup and incremental backup creation time. @@ -2209,7 +2209,7 @@ static void rocksdb_lock_checkpoint() MYSQL_ROW r = mysql_fetch_row(res); if (r && r[0] && strcmp(r[0], "1")) { - msg("Could not obtain rocksdb checkpont lock."); + msg("Could not obtain rocksdb checkpoint lock."); exit(EXIT_FAILURE); } mysql_free_result(res); diff --git a/extra/mariabackup/backup_mysql.cc b/extra/mariabackup/backup_mysql.cc index e4a39244bbf..e1368757268 100644 --- a/extra/mariabackup/backup_mysql.cc +++ b/extra/mariabackup/backup_mysql.cc @@ -101,7 +101,7 @@ extern my_bool opt_ssl_verify_server_cert, opt_use_ssl; /* get_os_user() - Ressemles read_user_name() from libmariadb/libmariadb/mariadb_lib.c. + Resembles read_user_name() from libmariadb/libmariadb/mariadb_lib.c. */ #if !defined(_WIN32) @@ -1405,7 +1405,7 @@ are used because donor's wsrep_gtid_domain_id is needed later in joiner. Note that at this stage wsrep_local_state_uuid and wsrep_last_committed are inconsistent but they are not used in joiner. Joiner will rewrite this file at mariabackup --prepare phase and thus there is extra file donor_galera_info. -Information is needed to maitain wsrep_gtid_domain_id and gtid_binlog_pos +Information is needed to maintain wsrep_gtid_domain_id and gtid_binlog_pos same across the cluster. If joiner node have different wsrep_gtid_domain_id we should still receive effective domain id from the donor node, and use it. diff --git a/extra/mariabackup/xbcloud.cc b/extra/mariabackup/xbcloud.cc index fa5dc79edbc..0456620bb2b 100644 --- a/extra/mariabackup/xbcloud.cc +++ b/extra/mariabackup/xbcloud.cc @@ -1484,7 +1484,7 @@ struct download_buffer_info { }; /*********************************************************************//** -Callback to parse header of GET request on swift contaier. */ +Callback to parse header of GET request on swift container. */ static size_t fetch_buffer_header_cb(char *ptr, size_t size, size_t nmemb, void *data) @@ -1686,7 +1686,7 @@ container_list_add_object(container_list *list, const char *name, /*********************************************************************//** -Tokenize json string. Return array of tokens. Caller is responsoble for +Tokenize json string. Return array of tokens. Caller is responsible for deallocating the array. */ jsmntok_t * json_tokenise(char *json, size_t len, int initial_tokens) diff --git a/extra/mariabackup/xtrabackup.cc b/extra/mariabackup/xtrabackup.cc index 34d63148381..139a16cf1cd 100644 --- a/extra/mariabackup/xtrabackup.cc +++ b/extra/mariabackup/xtrabackup.cc @@ -219,7 +219,7 @@ uint xtrabackup_compress = FALSE; uint xtrabackup_compress_threads; ulonglong xtrabackup_compress_chunk_size = 0; -/* sleep interval beetween log copy iterations in log copying thread +/* sleep interval between log copy iterations in log copying thread in milliseconds (default is 1 second) */ ulint xtrabackup_log_copy_interval = 1000; static ulong max_buf_pool_modified_pct; @@ -431,7 +431,7 @@ typedef decltype(fil_space_t::id) space_id_t; typedef std::map space_id_to_name_t; struct ddl_tracker_t { - /** Tablspaces with their ID and name, as they were copied to backup.*/ + /** Tablespaces with their ID and name, as they were copied to backup.*/ space_id_to_name_t tables_in_backup; /** Drop operations found in redo log. */ std::set drops; @@ -651,7 +651,7 @@ void CorruptedPages::zero_out_free_pages() { uint32_t space_id = space_it->first; const std::string &space_name = space_it->second.space_name; - // There is no need to close tablespaces explixitly as they will be closed + // There is no need to close tablespaces explicitly as they will be closed // in innodb_shutdown(). xb_load_single_table_tablespace(space_name, false); fil_space_t *space = fil_space_t::get(space_id); @@ -5333,7 +5333,7 @@ class BackupStages { /* The only reason why Galera/binlog info is written before wait_for_ibbackup_log_copy_finish() is that after that call the xtrabackup - binary will start streamig a temporary copy of REDO log to stdout and + binary will start streaming a temporary copy of REDO log to stdout and thus, any streaming from innobackupex would interfere. The only way to avoid that is to have a single process, i.e. merge innobackupex and xtrabackup. */ @@ -6364,7 +6364,7 @@ and ".idb.meta" files in incremental directory to avoid applying delta to @param[in] db_name database name @param[in] file_name file name with suffix @param[in] arg destination path, used in incremental backup to notify, that -*.new file must be moved to destibation directory +*.new file must be moved to destination directory @return true */ static ibool prepare_handle_new_files(const char *data_home_dir, diff --git a/extra/perror.c b/extra/perror.c index 8f4c92fbfd0..83b8d6eb8cd 100644 --- a/extra/perror.c +++ b/extra/perror.c @@ -315,7 +315,7 @@ int main(int argc,char *argv[]) code=atoi(*argv); msg = strerror(code); - // On AIX, unknow error return " Error occurred." + // On AIX, unknown error returns " Error occurred." snprintf(unknow_aix, sizeof(unknow_aix), " Error %3d occurred.", code); /* diff --git a/extra/replace.c b/extra/replace.c index 81c7f484bdf..a28463fd30f 100644 --- a/extra/replace.c +++ b/extra/replace.c @@ -332,7 +332,7 @@ static void free_pointer_array(reg1 POINTER_ARRAY *pa) } /* free_pointer_array */ - /* Code for replace rutines */ + /* Code for replace routines */ #define SET_MALLOC_HUNC 64 @@ -342,7 +342,7 @@ typedef struct st_rep_set { uint found_len; /* Best match to date */ int found_offset; uint table_offset; - uint size_of_bits; /* For convinience */ + uint size_of_bits; /* For convenience */ } REP_SET; typedef struct st_rep_sets { diff --git a/include/json_lib.h b/include/json_lib.h index d4632788ecc..868f09ca495 100644 --- a/include/json_lib.h +++ b/include/json_lib.h @@ -37,7 +37,7 @@ typedef struct st_json_string_t const uchar *c_str; /* Current position in JSON string */ const uchar *str_end; /* The end on the string. */ my_wc_t c_next; /* UNICODE of the last read character */ - int c_next_len; /* character lenght of the last read character. */ + int c_next_len; /* character length of the last read character. */ int error; /* error code. */ CHARSET_INFO *cs; /* Character set of the JSON string. */ diff --git a/include/lf.h b/include/lf.h index 267a66aeeaf..43a0cb1af28 100644 --- a/include/lf.h +++ b/include/lf.h @@ -125,7 +125,7 @@ void *lf_alloc_new(LF_PINS *pins); C_MODE_END /* - extendible hash, lf_hash.cc + extensible hash, lf_hash.cc */ #include diff --git a/include/m_ctype.h b/include/m_ctype.h index d6d9f107cc5..788f0f7267e 100644 --- a/include/m_ctype.h +++ b/include/m_ctype.h @@ -1347,7 +1347,7 @@ my_ci_scan(CHARSET_INFO *cs, const char *b, const char *e, int seq) @return 1 on a single byte character @return >1 on a multi-byte character - Note, inlike my_ismbchar(), 1 is returned for a single byte character. + Note, unlike my_ismbchar(), 1 is returned for a single byte character. */ static inline int diff --git a/include/my_base.h b/include/my_base.h index d1db12ecff6..94d1053e529 100644 --- a/include/my_base.h +++ b/include/my_base.h @@ -463,7 +463,7 @@ enum ha_base_keytype { #define HA_ERR_RETRY_INIT 129 /* Initialization failed and should be retried */ #define HA_ERR_NOT_A_TABLE 130 /* not a MYI file - no signature */ #define HA_ERR_WRONG_COMMAND 131 /* Command not supported */ -#define HA_ERR_OLD_FILE 132 /* old databasfile */ +#define HA_ERR_OLD_FILE 132 /* old database file */ #define HA_ERR_NO_ACTIVE_RECORD 133 /* No record read in update() */ #define HA_ERR_RECORD_DELETED 134 /* A record is not there */ #define HA_ERR_RECORD_FILE_FULL 135 /* No more room in file */ diff --git a/include/my_byteorder.h b/include/my_byteorder.h index acd3f490136..2939ae07353 100644 --- a/include/my_byteorder.h +++ b/include/my_byteorder.h @@ -52,7 +52,7 @@ #include "little_endian.h" #endif -/* convenienve helpers */ +/* convenience helpers */ static inline float get_float(const void *from) { float to; diff --git a/include/my_compare.h b/include/my_compare.h index 1d66e51ef83..44ae7022a2c 100644 --- a/include/my_compare.h +++ b/include/my_compare.h @@ -263,7 +263,7 @@ extern HA_KEYSEG *ha_find_null(HA_KEYSEG *keyseg, const uchar *a); returned to the SQL layer. 2=CHECK_OUT_OF_RANGE - the index tuple is outside of the range that we're scanning. (Example: if we're scanning "t.key BETWEEN 10 AND - 20" and got a "t.key=21" tuple) Tthe engine should stop + 20" and got a "t.key=21" tuple, the engine should stop scanning and return HA_ERR_END_OF_FILE right away). 3=CHECK_ABORTED_BY_USER - the engine must stop scanning and should return HA_ERR_ABORTED_BY_USER right away diff --git a/include/my_getopt.h b/include/my_getopt.h index b839baa68ce..897db3b14ce 100644 --- a/include/my_getopt.h +++ b/include/my_getopt.h @@ -71,7 +71,7 @@ struct my_option is created, but a long option still can be identified uniquely in the my_get_one_option() callback. - If an opton needs neither special + If an option needs neither special treatment in the my_get_one_option() nor one-letter short equivalent use id=0 diff --git a/include/my_global.h b/include/my_global.h index b51d34bfd9a..e9b68bd21d0 100644 --- a/include/my_global.h +++ b/include/my_global.h @@ -489,7 +489,7 @@ typedef unsigned short ushort; #include /* - Wen using the embedded library, users might run into link problems, + When using the embedded library, users might run into link problems, duplicate declaration of __cxa_pure_virtual, solved by declaring it a weak symbol. */ @@ -684,7 +684,7 @@ typedef SOCKET_SIZE_TYPE size_socket; */ #define MALLOC_OVERHEAD (8+24) - /* get memory in huncs */ + /* get memory in hunks */ #define ONCE_ALLOC_INIT (uint) 4096 /* Typical record cache */ #define RECORD_CACHE_SIZE (uint) (128*1024) diff --git a/include/my_sys.h b/include/my_sys.h index e129f03ff3c..b3d816ad39c 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -463,7 +463,7 @@ typedef struct st_io_cache /* Used when caching files */ int (*write_function)(struct st_io_cache *,const uchar *,size_t); /* Specifies the type of the cache. Depending on the type of the cache - certain operations might not be available and yield unpredicatable + certain operations might not be available and yield unpredictable results. Details to be documented later */ enum cache_type type; diff --git a/include/my_xml.h b/include/my_xml.h index 846448a06d9..c13f91a976b 100644 --- a/include/my_xml.h +++ b/include/my_xml.h @@ -34,7 +34,7 @@ extern "C" { #define MY_XML_FLAG_RELATIVE_NAMES 1 /* - A flag whether to skip normilization of text values before calling + A flag whether to skip normalization of text values before calling call-back functions: i.e. skip leading/trailing spaces, \r, \n, \t characters. */ diff --git a/include/mysql/plugin.h b/include/mysql/plugin.h index c89da500e3a..2bf5455cdea 100644 --- a/include/mysql/plugin.h +++ b/include/mysql/plugin.h @@ -102,7 +102,7 @@ typedef struct st_mysql_xid MYSQL_XID; /* MariaDB plugin types */ /** Client and server password validation */ #define MariaDB_PASSWORD_VALIDATION_PLUGIN 8 -/**< Encryption and key managment plugins */ +/**< Encryption and key management plugins */ #define MariaDB_ENCRYPTION_PLUGIN 9 /**< Plugins for SQL data storage types */ #define MariaDB_DATA_TYPE_PLUGIN 10 diff --git a/include/mysql/plugin_encryption.h b/include/mysql/plugin_encryption.h index a036e2215d8..494e010e481 100644 --- a/include/mysql/plugin_encryption.h +++ b/include/mysql/plugin_encryption.h @@ -99,7 +99,7 @@ struct st_mariadb_encryption writes the output to the dst buffer. note that it might write more bytes that were in the input. or less. or none at all. - dlen points to the starting lenght of the output buffer. Upon return, it + dlen points to the starting length of the output buffer. Upon return, it should be set to the number of bytes written. */ int (*crypt_ctx_update)(void *ctx, const unsigned char* src, unsigned int slen, diff --git a/include/mysql/psi/psi.h b/include/mysql/psi/psi.h index 48abf93b627..976ac95acab 100644 --- a/include/mysql/psi/psi.h +++ b/include/mysql/psi/psi.h @@ -2374,7 +2374,7 @@ typedef void (*destroy_prepared_stmt_v1_t) (PSI_prepared_stmt *prepared_stmt); /** - repreare a prepare statement. + reprepare a prepare statement. @param prepared_stmt prepared statement. */ typedef void (*reprepare_prepared_stmt_v1_t) diff --git a/libmysqld/libmysql.c b/libmysqld/libmysql.c index 01fda8ea8d0..11f45e03273 100644 --- a/libmysqld/libmysql.c +++ b/libmysqld/libmysql.c @@ -2208,7 +2208,7 @@ int cli_stmt_execute(MYSQL_STMT *stmt) DBUG_RETURN(1); } length= (ulong) (net->write_pos - net->buff); - /* TODO: Look into avoding the following memdup */ + /* TODO: Look into avoiding the following memdup */ if (!(param_data= my_memdup(PSI_NOT_INSTRUMENTED, net->buff, length, MYF(0)))) { set_stmt_error(stmt, CR_OUT_OF_MEMORY, unknown_sqlstate, NULL); diff --git a/mysys/array.c b/mysys/array.c index dee6459e2e0..36619e82be4 100644 --- a/mysys/array.c +++ b/mysys/array.c @@ -33,7 +33,7 @@ DESCRIPTION init_dynamic_array() initiates array and allocate space for - init_alloc eilements. + init_alloc elements. Array is usable even if space allocation failed, hence, the function never returns TRUE. @@ -280,7 +280,7 @@ my_bool allocate_dynamic(DYNAMIC_ARRAY *array, size_t max_elements) if (array->malloc_flags & MY_INIT_BUFFER_USED) { /* - In this senerio, the buffer is statically preallocated, + In this scenario, the buffer is statically preallocated, so we have to create an all-new malloc since we overflowed */ if (!(new_ptr= (uchar *) my_malloc(array->m_psi_key, size * diff --git a/mysys/crc32/crc32_arm64.c b/mysys/crc32/crc32_arm64.c index c39f7b5f6f6..cdeaa85ab37 100644 --- a/mysys/crc32/crc32_arm64.c +++ b/mysys/crc32/crc32_arm64.c @@ -370,7 +370,7 @@ static unsigned crc32c_aarch64_pmull(unsigned crc, const void *buf, size_t len) /* There are multiple approaches to calculate crc. Approach-1: Process 8 bytes then 4 bytes then 2 bytes and then 1 bytes Approach-2: Process 8 bytes and remaining workload using 1 bytes -Apporach-3: Process 64 bytes at once by issuing 8 crc call and remaining +Approach-3: Process 64 bytes at once by issuing 8 crc call and remaining using 8/1 combination. Based on micro-benchmark testing we found that Approach-2 works best especially diff --git a/mysys/crc32/crc32_x86.c b/mysys/crc32/crc32_x86.c index ab2522d61cf..f22d9be10d2 100644 --- a/mysys/crc32/crc32_x86.c +++ b/mysys/crc32/crc32_x86.c @@ -112,7 +112,7 @@ struct crcr_pclmulqdq_ctx * FOLD = XOR(T1, T2, DATA) * * @param data_block 16 byte data block - * @param precomp precomputed rk1 constanst + * @param precomp precomputed rk1 constant * @param fold running 16 byte folded data * * @return New 16 byte folded data diff --git a/mysys/crc32/crc_ppc64.h b/mysys/crc32/crc_ppc64.h index 81bbc16dfed..b2b1cdfc832 100644 --- a/mysys/crc32/crc_ppc64.h +++ b/mysys/crc32/crc_ppc64.h @@ -105,7 +105,7 @@ out: #endif /* When we have a load-store in a single-dispatch group and address overlap - * such that foward is not allowed (load-hit-store) the group must be flushed. + * such that forward is not allowed (load-hit-store) the group must be flushed. * A group ending NOP prevents the flush. */ #define GROUP_ENDING_NOP asm("ori 2,2,0" ::: "memory") diff --git a/mysys/hash.c b/mysys/hash.c index e3ab80bf077..5d361a3431b 100644 --- a/mysys/hash.c +++ b/mysys/hash.c @@ -62,7 +62,7 @@ my_hash_value_type my_hash_sort(CHARSET_INFO *cs, const uchar *key, @param[in] psi_key The key to register instrumented memory @param[in,out] hash The hash that is initialized - @param[in] growth_size size incrememnt for the underlying dynarray + @param[in] growth_size size increment for the underlying dynarray @param[in] charset The character set information @param[in] size The hash size @param[in] key_offest The key offset for the hash diff --git a/mysys/lf_hash.cc b/mysys/lf_hash.cc index c8f2e3f456f..444bc5cd042 100644 --- a/mysys/lf_hash.cc +++ b/mysys/lf_hash.cc @@ -119,7 +119,7 @@ retry: MY_MEMORY_ORDER_ACQUIRE); do { - /* attempting to my_assume_aligned onlink below broke the implementation */ + /* attempting to my_assume_aligned on link below broke the implementation */ link= (intptr) my_atomic_loadptr_explicit((void **) &cursor->curr->link, MY_MEMORY_ORDER_RELAXED); cursor->next= my_assume_aligned(PTR(link)); diff --git a/mysys/ma_dyncol.c b/mysys/ma_dyncol.c index 60aaffba227..6bb03cfad95 100644 --- a/mysys/ma_dyncol.c +++ b/mysys/ma_dyncol.c @@ -3588,7 +3588,7 @@ dynamic_column_update_many_fmt(DYNAMIC_COLUMN *str, entry_size, header_size, new_header.offset_size, new_header.entry_size, - new_heder.header_size, column_count, + new_header.header_size, column_count, new_header.column_count, add_column_count, header_end, header.data_size); @@ -3669,7 +3669,7 @@ mariadb_dyncol_check(DYNAMIC_COLUMN *str) if (fmt->fixed_hdr + header.header_size + header.nmpool_size > str->length) { DBUG_PRINT("info", ("Fixed header: %u Header size: %u " - "Name pool size: %u but Strig length: %u", + "Name pool size: %u but String length: %u", (uint)fmt->fixed_hdr, (uint)header.header_size, (uint)header.nmpool_size, @@ -3776,7 +3776,7 @@ mariadb_dyncol_check(DYNAMIC_COLUMN *str) i++, header.entry+= header.entry_size) { DYNAMIC_COLUMN_VALUE store; - // already checked by previouse pass + // already checked by previous pass (*fmt->type_and_offset_read)(&header.type, &header.offset, header.entry + fmt->fixed_hdr_entry, header.offset_size); diff --git a/mysys/mf_iocache.c b/mysys/mf_iocache.c index 2641281ad07..fabd9237e1c 100644 --- a/mysys/mf_iocache.c +++ b/mysys/mf_iocache.c @@ -16,7 +16,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA */ /* - Cashing of files with only does (sequential) read or writes of fixed- + Caсhing of files with only does (sequential) read or writes of fixed- length records. A read isn't allowed to go over file-length. A read is ok if it ends at file-length and next read can try to read after file-length (and get a EOF-error). @@ -26,7 +26,7 @@ One can change info->pos_in_file to a higher value to skip bytes in file if also info->read_pos is set to info->read_end. If called through open_cached_file(), then the temporary file will - only be created if a write exeeds the file buffer or if one calls + only be created if a write exceeds the file buffer or if one calls my_b_flush_io_cache(). If one uses SEQ_READ_APPEND, then two buffers are allocated, one for diff --git a/mysys/mf_iocache2.c b/mysys/mf_iocache2.c index e134524af97..b7819839d6f 100644 --- a/mysys/mf_iocache2.c +++ b/mysys/mf_iocache2.c @@ -269,7 +269,7 @@ size_t my_b_gets(IO_CACHE *info, char *to, size_t max_length) } if (!(max_length-=length)) { - /* Found enough charcters; Return found string */ + /* Found enough characters; Return found string */ info->read_pos=pos; *to='\0'; return (size_t) (to-start); diff --git a/mysys/mf_keycache.c b/mysys/mf_keycache.c index 2307341ddb2..6cd7f56b51d 100644 --- a/mysys/mf_keycache.c +++ b/mysys/mf_keycache.c @@ -442,7 +442,7 @@ static inline uint next_power(uint value) init_simple_key_cache() keycache pointer to the control block of a simple key cache key_cache_block_size size of blocks to keep cached data - use_mem memory to use for the key cache buferrs/structures + use_mem memory to use for the key cache buffers/structures division_limit division limit (may be zero) age_threshold age threshold (may be zero) @@ -1525,7 +1525,7 @@ static void unlink_block(SIMPLE_KEY_CACHE_CB *keycache, BLOCK_LINK *block) NOTE The first request unlinks the block from the LRU ring. This means - that it is protected against eveiction. + that it is protected against eviction. RETURN void @@ -2028,7 +2028,7 @@ restart: everything can happen to the block but free or another completed eviction. - Note that we bahave like a secondary requestor here. We just + Note that we behave like a secondary requestor here. We just cannot return with PAGE_WAIT_TO_BE_READ. This would work for read requests and writes on dirty blocks that are not in flush only. Waiting here on COND_FOR_REQUESTED works in all @@ -3702,7 +3702,7 @@ static void free_block(SIMPLE_KEY_CACHE_CB *keycache, BLOCK_LINK *block) /* Unregister the block request and link the block into the LRU ring. This enables eviction for the block. If the LRU ring was empty and - threads are waiting for a block, then the block wil be handed over + threads are waiting for a block, then the block will be handed over for eviction immediately. Otherwise we will unlink it from the LRU ring again, without releasing the lock in between. So decrementing the request counter and updating statistics are the only relevant @@ -3788,7 +3788,7 @@ static int flush_cached_blocks(SIMPLE_KEY_CACHE_CB *keycache, keycache_pthread_mutex_unlock(&keycache->cache_lock); /* As all blocks referred in 'cache' are marked by BLOCK_IN_FLUSH - we are guarunteed no thread will change them + we are guaranteed no thread will change them */ my_qsort((uchar*) cache, count, sizeof(*cache), (qsort_cmp) cmp_sec_link); @@ -4113,7 +4113,7 @@ restart: { if ((error= flush_cached_blocks(keycache, file, cache, pos, type))) { - /* Do not loop inifnitely trying to flush in vain. */ + /* Do not loop infinitely trying to flush in vain. */ if ((last_errno == error) && (++last_errcnt > 5)) goto err; last_errno= error; @@ -6121,7 +6121,7 @@ int resize_key_cache(KEY_CACHE *keycache, uint key_cache_block_size, DESCRIPTION The function sets new values of the division limit and the age threshold - used when the key cache keycach employs midpoint insertion strategy. + used when the key cache keycache employs midpoint insertion strategy. The parameters division_limit and age_threshold provide these new values. RETURN VALUE diff --git a/mysys/mf_qsort.c b/mysys/mf_qsort.c index 4dee20750c0..c5ea3bebdc0 100644 --- a/mysys/mf_qsort.c +++ b/mysys/mf_qsort.c @@ -187,7 +187,7 @@ qsort_t my_qsort(void *base_ptr, size_t count, size_t size, qsort_cmp cmp) Prepare for next iteration. Skip partitions of size 1 as these doesn't have to be sorted Push the larger partition and sort the smaller one first. - This ensures that the stack is keept small. + This ensures that the stack is kept small. */ if ((int) (high_ptr - low) <= 0) diff --git a/mysys/mf_qsort2.c b/mysys/mf_qsort2.c index cee460f8de1..1e502fdca0c 100644 --- a/mysys/mf_qsort2.c +++ b/mysys/mf_qsort2.c @@ -14,7 +14,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA */ -/* qsort that sends one extra argument to the compare subrutine */ +/* qsort that sends one extra argument to the compare subroutine */ #define QSORT_EXTRA_CMP_ARGUMENT #include "mf_qsort.c" diff --git a/mysys/mf_radix.c b/mysys/mf_radix.c index 89a3c4ac6ce..cf03aae947d 100644 --- a/mysys/mf_radix.c +++ b/mysys/mf_radix.c @@ -16,8 +16,8 @@ /* Radixsort for pointers to fixed length strings. - A very quick sort for not to long (< 20 char) strings. - Neads a extra buffers of number_of_elements pointers but is + A very quick sort for not too long (< 20 char) strings. + Needs extra buffers of number_of_elements pointers but is 2-3 times faster than quicksort */ diff --git a/mysys/mf_wcomp.c b/mysys/mf_wcomp.c index 6fb19ebae69..e4aab52c333 100644 --- a/mysys/mf_wcomp.c +++ b/mysys/mf_wcomp.c @@ -14,7 +14,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA */ -/* Funktions for comparing with wild-cards */ +/* Functions for comparing with wild-cards */ #include "mysys_priv.h" diff --git a/mysys/my_bitmap.c b/mysys/my_bitmap.c index af102ab0696..1451834ce9d 100644 --- a/mysys/my_bitmap.c +++ b/mysys/my_bitmap.c @@ -97,7 +97,7 @@ static inline my_bitmap_map last_bit_mask(uint bits) /* Get a mask of the bits that are to be considered as 'on' at location starting with 'bits'. - This function has _inv in it's name as it's usage is invers compared + This function has _inv in its name as its usage is the inverse compared to last_bit_mask(). For (bits & 63) it will return values from the series diff --git a/mysys/my_compare.c b/mysys/my_compare.c index d1326dc9d04..0f6c02553b4 100644 --- a/mysys/my_compare.c +++ b/mysys/my_compare.c @@ -40,7 +40,7 @@ static int compare_bin(const uchar *a, uint a_length, /* We are using space compression. We have to check if longer key has next character < ' ', in which case it's less than the shorter - key that has an implicite space afterwards. + key that has an implicit space afterwards. This code is identical to the one in strings/ctype-simple.c:my_strnncollsp_simple diff --git a/mysys/my_copy.c b/mysys/my_copy.c index 3b07dd5fd53..8f1b3f406de 100644 --- a/mysys/my_copy.c +++ b/mysys/my_copy.c @@ -106,7 +106,7 @@ int my_copy(const char *from, const char *to, myf MyFlags) /* Copy modes if possible */ if (MyFlags & MY_HOLD_ORIGINAL_MODES && !new_file_stat) - DBUG_RETURN(0); /* File copyed but not stat */ + DBUG_RETURN(0); /* File copied but not stat */ /* Copy modes */ if (chmod(to, stat_buff.st_mode & 07777)) { diff --git a/mysys/my_default.c b/mysys/my_default.c index e63a3a8abd3..7f132fe3e3f 100644 --- a/mysys/my_default.c +++ b/mysys/my_default.c @@ -526,7 +526,7 @@ static int search_default_file(struct handle_option_ctx *ctx, const char *dir, get_argument() keyword Include directive keyword kwlen Length of keyword - ptr Pointer to the keword in the line under process + ptr Pointer to the keyword in the line under process line line number RETURN @@ -857,7 +857,7 @@ static int search_default_file_with_ext(struct handle_option_ctx *ctx, static char *remove_end_comment(char *ptr) { char quote= 0; /* we are inside quote marks */ - char escape= 0; /* symbol is protected by escape chagacter */ + char escape= 0; /* symbol is protected by escape character */ for (; *ptr; ptr++) { diff --git a/mysys/my_delete.c b/mysys/my_delete.c index 6854033f84b..c63ad5e2a24 100644 --- a/mysys/my_delete.c +++ b/mysys/my_delete.c @@ -229,7 +229,7 @@ int my_rmtree(const char *dir, myf MyFlags) #ifdef _WIN32 /* On Windows, check and possible reset readonly attribute. - my_delete(), or DeleteFile does not remove theses files. + my_delete(), or DeleteFile does not remove these files. */ if (err) { diff --git a/mysys/my_fopen.c b/mysys/my_fopen.c index 2bc1da52d66..a7da230ceea 100644 --- a/mysys/my_fopen.c +++ b/mysys/my_fopen.c @@ -277,7 +277,7 @@ static void make_ftype(register char * to, register int flag) *to++= (flag & O_APPEND) ? 'a' : 'w'; else if (flag & O_RDWR) { - /* Add '+' after theese */ + /* Add '+' after these */ if (flag & (O_TRUNC | O_CREAT)) *to++= 'w'; else if (flag & O_APPEND) diff --git a/mysys/my_getopt.c b/mysys/my_getopt.c index 56f947e6791..adfc8e313b2 100644 --- a/mysys/my_getopt.c +++ b/mysys/my_getopt.c @@ -73,7 +73,7 @@ my_bool my_getopt_skip_unknown= 0; /* This is a flag that can be set in client programs. 1 means that - my_getopt will reconize command line options by their unambiguous + my_getopt will recognize command line options by their unambiguous prefixes. 0 means an option must be always specified in full. */ my_bool my_getopt_prefix_matching= 1; @@ -920,7 +920,7 @@ static int setval(const struct my_option *opts, void *value, char *argument, /* This sets a bit stored in a longlong. The bit to set is stored in block_size. If block_size is positive - then setting the bit means value is true. If block_size is negatitive, + then setting the bit means value is true. If block_size is negative, then setting the bit means value is false. */ tmp= get_bool_argument(opts, argument); diff --git a/mysys/my_largepage.c b/mysys/my_largepage.c index 71527a9bc27..2c74ddd9ddc 100644 --- a/mysys/my_largepage.c +++ b/mysys/my_largepage.c @@ -443,10 +443,10 @@ void my_large_free(void *ptr, size_t size) For ASAN, we need to explicitly unpoison this memory region because the OS may reuse that memory for some TLS or stack variable. It will remain - poisoned if it was explicitly poisioned before release. If this happens, + poisoned if it was explicitly poisoned before release. If this happens, we'll have hard to debug false positives like in MDEV-21239. For valgrind, we mark it as UNDEFINED rather than NOACCESS because of the - implict reuse possiblility. + implicit reuse possibility. */ #if defined(HAVE_MMAP) && !defined(_WIN32) if (munmap(ptr, size)) diff --git a/mysys/my_lib.c b/mysys/my_lib.c index f905e757869..8f2de91a029 100644 --- a/mysys/my_lib.c +++ b/mysys/my_lib.c @@ -201,7 +201,7 @@ err_open: /* ***************************************************************************** -** Read long filename using windows rutines +** Read long filename using windows routines ***************************************************************************** */ diff --git a/mysys/my_minidump.cc b/mysys/my_minidump.cc index d81aab2f764..56e16aa9862 100644 --- a/mysys/my_minidump.cc +++ b/mysys/my_minidump.cc @@ -50,7 +50,7 @@ extern "C" BOOL my_create_minidump(DWORD pid, BOOL verbose) if (filename) { filename++; - // We are not interested in dump of some proceses (my_safe_process.exe,cmd.exe) + // We are not interested in dump of some processes (my_safe_process.exe,cmd.exe) // since they are only used to start up other programs. // We're interested however in their children; const char *exclude_programs[] = {"my_safe_process.exe","cmd.exe", 0}; diff --git a/mysys/my_pthread.c b/mysys/my_pthread.c index d29bbe60d8a..8d7d9ce124d 100644 --- a/mysys/my_pthread.c +++ b/mysys/my_pthread.c @@ -383,7 +383,7 @@ int my_pthread_mutex_trylock(pthread_mutex_t *mutex) int error= pthread_mutex_trylock(mutex); if (error == 1) return 0; /* Got lock on mutex */ - if (error == 0) /* Someon else is locking mutex */ + if (error == 0) /* Someone else is locking mutex */ return EBUSY; if (error == -1) /* Safety if the lib is fixed */ error= errno; /* Probably invalid parameter */ diff --git a/mysys/my_rdtsc.c b/mysys/my_rdtsc.c index a5a6ccdbb8e..c0a4e9518d5 100644 --- a/mysys/my_rdtsc.c +++ b/mysys/my_rdtsc.c @@ -778,7 +778,7 @@ void my_timer_init(MY_TIMER_INFO *mti) Any clock-based timer can be affected by NPT (ntpd program), which means: - full-second correction can occur for leap second - - tiny corrections can occcur approimately every 11 minutes + - tiny corrections can occur approximately every 11 minutes (but I think they only affect the RTC which isn't the PIT). We define "precision" as "frequency" and "high precision" is diff --git a/mysys/my_rnd.c b/mysys/my_rnd.c index b1dd8b1f36f..826de85052b 100644 --- a/mysys/my_rnd.c +++ b/mysys/my_rnd.c @@ -28,7 +28,7 @@ void my_rnd_init(struct my_rnd_struct *rand_st, ulong seed1, ulong seed2) { #ifdef HAVE_valgrind - bzero((char*) rand_st,sizeof(*rand_st)); /* Avoid UMC varnings */ + bzero((char*) rand_st,sizeof(*rand_st)); /* Avoid UMC warnings */ #endif rand_st->max_value= 0x3FFFFFFFL; rand_st->max_value_dbl=(double) rand_st->max_value; diff --git a/mysys/my_sync.c b/mysys/my_sync.c index 6f8760c3183..f3f0ee3758a 100644 --- a/mysys/my_sync.c +++ b/mysys/my_sync.c @@ -36,7 +36,7 @@ void thr_set_sync_wait_callback(void (*before_wait)(void), SYNOPSIS my_sync() - fd File descritor to sync + fd File descriptor to sync my_flags Flags (now only MY_WME is supported) NOTE diff --git a/mysys/my_thr_init.c b/mysys/my_thr_init.c index f40dab43fa8..c8f3569a7e8 100644 --- a/mysys/my_thr_init.c +++ b/mysys/my_thr_init.c @@ -15,7 +15,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA */ /* - Functions to handle initializating and allocationg of all mysys & debug + Functions to handle initializating and allocating of all mysys & debug thread variables. */ @@ -202,7 +202,7 @@ void my_thread_global_end(void) THR_thread_count); #endif /* HAVE_PTHREAD_KILL */ #ifdef SAFEMALLOC - /* We know we will have memoryleaks, suppress the leak report */ + /* We know we will have memory leaks, suppress the leak report */ sf_leaking_memory= 1; #endif /* SAFEMALLOC */ all_threads_killed= 0; diff --git a/mysys/my_winfile.c b/mysys/my_winfile.c index 7a1e3e60b12..cce0c0bdb22 100644 --- a/mysys/my_winfile.c +++ b/mysys/my_winfile.c @@ -41,7 +41,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA */ range in my_win_* function will be punished with DBUG_ASSERT() - File streams (FILE *) are actually from the C runtime. The routines provided - here are useful only in scernarios that use low-level IO with my_win_fileno() + here are useful only in scenarios that use low-level IO with my_win_fileno() */ #ifdef _WIN32 diff --git a/mysys/my_write.c b/mysys/my_write.c index 06914b25641..afbd6d94f93 100644 --- a/mysys/my_write.c +++ b/mysys/my_write.c @@ -93,7 +93,7 @@ size_t my_write(File Filedes, const uchar *Buffer, size_t Count, myf MyFlags) if (!writtenbytes && !errors++) /* Retry once */ { - /* We may come here if the file quota is exeeded */ + /* We may come here if the file quota is exceeded */ errno= EFBIG; /* Assume this is the error */ continue; } diff --git a/mysys/ptr_cmp.c b/mysys/ptr_cmp.c index 40af3f63afd..89e3dfd7425 100644 --- a/mysys/ptr_cmp.c +++ b/mysys/ptr_cmp.c @@ -25,7 +25,7 @@ * On some platforms, memcmp() is faster than the unrolled ptr_compare_N * functions, as memcmp() is usually a platform-specific implementation * written in assembler. for example one in /usr/lib/libc/libc_hwcap*.so.1. - * on Solaris, or on Windows inside C runtime linrary. + * on Solaris, or on Windows inside C runtime library. * * On Solaris, native implementation is also usually faster than the * built-in memcmp supplied by GCC, so it is recommended to build @@ -35,7 +35,7 @@ /* Daniel Blacks tests shows that libc memcmp is generally faster than ptr_cmp() at least of x86 and power8 platforms, so we use the libc - code as deafult for now + code as default for now */ #define USE_NATIVE_MEMCMP 1 diff --git a/mysys/queues.c b/mysys/queues.c index 07b3b4f7ed1..17ac86c832a 100644 --- a/mysys/queues.c +++ b/mysys/queues.c @@ -26,7 +26,7 @@ /* This code originates from the Unireg project. - Code for generell handling of priority Queues. + Code for general handling of priority Queues. Implementation of queues from "Algorithms in C" by Robert Sedgewick. The queue can optionally store the position in queue in the element diff --git a/mysys/stacktrace.c b/mysys/stacktrace.c index f203bba4d8d..adce4d0f66e 100644 --- a/mysys/stacktrace.c +++ b/mysys/stacktrace.c @@ -55,7 +55,7 @@ static sig_handler default_handle_fatal_signal(int sig) /** - Initialize priting off stacktrace at signal + Initialize printing of stacktrace at signal */ void my_setup_stacktrace(void) diff --git a/mysys/string.c b/mysys/string.c index 91e4306ced4..6720f3fd4ef 100644 --- a/mysys/string.c +++ b/mysys/string.c @@ -133,7 +133,7 @@ my_bool dynstr_trunc(DYNAMIC_STRING *str, size_t n) to specified DYNAMIC_STRING. This function is especially useful when building strings to be executed with the system() function. - @param str Dynamic String which will have addtional strings appended. + @param str Dynamic String which will have additional strings appended. @param append String to be appended. @param ... Optional. Additional string(s) to be appended. diff --git a/mysys/tree.c b/mysys/tree.c index db0442fa827..f20752b7327 100644 --- a/mysys/tree.c +++ b/mysys/tree.c @@ -16,7 +16,7 @@ /* Code for handling red-black (balanced) binary trees. - key in tree is allocated accrding to following: + key in tree is allocated according to following: 1) If size < 0 then tree will not allocate keys and only a pointer to each key is saved in tree. @@ -780,7 +780,7 @@ static void rb_delete_fixup(TREE *tree, TREE_ELEMENT ***parent) #ifndef DBUG_OFF - /* Test that the proporties for a red-black tree holds */ + /* Test that the properties for a red-black tree holds */ static int test_rb_tree(TREE_ELEMENT *element) { diff --git a/mysys/typelib.c b/mysys/typelib.c index 10296c35bfb..bc90ef58429 100644 --- a/mysys/typelib.c +++ b/mysys/typelib.c @@ -293,7 +293,7 @@ static uint parse_name(const TYPELIB *lib, const char **pos, const char *end) } /** - Parse and apply a set of flag assingments + Parse and apply a set of flag assignments @param lib Flag names @param default_name Number of "default" in the typelib diff --git a/mysys/waiting_threads.c b/mysys/waiting_threads.c index 8f747092376..6cc89d086f9 100644 --- a/mysys/waiting_threads.c +++ b/mysys/waiting_threads.c @@ -40,7 +40,7 @@ a function that knows how to compare values of this resource type. In the simple case it could be wt_resource_id_memcmp(). - a wait-for graph - a graph, that represenst "wait-for" relationships. + a wait-for graph - a graph, that represents "wait-for" relationships. It has two types of nodes - threads and resources. There are directed edges from a thread to a resource it is waiting for (WT_THD::waiting_for), from a thread to resources that it "owns" (WT_THD::my_resources), @@ -669,7 +669,7 @@ retry: That is, only deadlocks that *we* have created. For example, thd->A->B->thd (thd waits for A, A waits for B, while B is waiting for thd). - While walking the graph we can encounter other cicles, e.g. + While walking the graph we can encounter other cycles, e.g. thd->A->B->C->A This will not be detected. Instead we will walk it in circles until the search depth limit is reached (the latter guarantees that an diff --git a/plugin/auth_gssapi/sspi_server.cc b/plugin/auth_gssapi/sspi_server.cc index 4a1958089ef..b2031bea7a7 100644 --- a/plugin/auth_gssapi/sspi_server.cc +++ b/plugin/auth_gssapi/sspi_server.cc @@ -345,7 +345,7 @@ static SECURITY_STATUS sspi_get_context(MYSQL_PLUGIN_VIO *vio, /* Send generated blob to client. */ if (vio->write_packet(vio, (unsigned char *)outbuf.pvBuffer, outbuf.cbBuffer)) { - log_error(SEC_E_OK, "communicaton error(write)"); + log_error(SEC_E_OK, "communication error(write)"); goto cleanup; } } diff --git a/plugin/disks/information_schema_disks.cc b/plugin/disks/information_schema_disks.cc index 01df32590eb..06eefe0b5db 100644 --- a/plugin/disks/information_schema_disks.cc +++ b/plugin/disks/information_schema_disks.cc @@ -39,7 +39,7 @@ /* This intends to support *BSD's, macOS, Solaris, AIX, HP-UX, and Linux. - specificly: + specifically: FreeBSD/OpenBSD/DragonFly/macOS (statfs) NetBSD (statvfs) uses getmntinfo(). Linux can use getmntent_r(), but we've just used getmntent for simplification. Linux/Solaris/AIX/HP-UX uses setmntent()/getmntent(). diff --git a/plugin/feedback/utils.cc b/plugin/feedback/utils.cc index efd9d0f59b5..c68dfe74718 100644 --- a/plugin/feedback/utils.cc +++ b/plugin/feedback/utils.cc @@ -381,7 +381,7 @@ int fill_linux_info(THD *thd, TABLE_LIST *tables) } /** - Adds varios bits of information to the I_S.FEEDBACK + Adds various bits of information to the I_S.FEEDBACK */ int fill_misc_data(THD *thd, TABLE_LIST *tables) { diff --git a/plugin/handler_socket/client/hslongrun.cpp b/plugin/handler_socket/client/hslongrun.cpp index a9fba1dc7c3..cda44fcc884 100644 --- a/plugin/handler_socket/client/hslongrun.cpp +++ b/plugin/handler_socket/client/hslongrun.cpp @@ -481,7 +481,7 @@ hs_longrun_thread_hs::op_insert(record_value& rec) cli->response_recv(numflds); if (arg.sh.verbose > 10) { const string_ref *row = cli->get_next_row(); - fprintf(stderr, "HS op=+ errrcode=%d errmess=[%s]\n", cli->get_error_code(), + fprintf(stderr, "HS op=+ errcode=%d errmess=[%s]\n", cli->get_error_code(), row ? to_string(row[0]).c_str() : ""); } const bool op_success = cli->get_error_code() == 0; diff --git a/plugin/handler_socket/handlersocket/database.hpp b/plugin/handler_socket/handlersocket/database.hpp index 87761050704..1d8171fc723 100644 --- a/plugin/handler_socket/handlersocket/database.hpp +++ b/plugin/handler_socket/handlersocket/database.hpp @@ -101,7 +101,7 @@ struct cmd_exec_args { uint32_t limit; uint32_t skip; string_ref mod_op; - const string_ref *uvals; /* size must be pst->retfieelds.size() */ + const string_ref *uvals; /* size must be pst->retfields.size() */ const record_filter *filters; int invalues_keypart; const string_ref *invalues; diff --git a/plugin/handler_socket/perl-Net-HandlerSocket/ppport.h b/plugin/handler_socket/perl-Net-HandlerSocket/ppport.h index 6e562f5b4a8..2a3d9e073b9 100644 --- a/plugin/handler_socket/perl-Net-HandlerSocket/ppport.h +++ b/plugin/handler_socket/perl-Net-HandlerSocket/ppport.h @@ -79,7 +79,7 @@ to be installed on your system. If this option is given, a copy of each file will be saved with the given suffix that contains the suggested changes. This does not require any external programs. Note that this does not -automagially add a dot between the original filename and the +automatically add a dot between the original filename and the suffix. If you want the dot, you have to include it in the option argument. diff --git a/plugin/password_reuse_check/password_reuse_check.c b/plugin/password_reuse_check/password_reuse_check.c index 47c9b4531a8..9caebc39f86 100644 --- a/plugin/password_reuse_check/password_reuse_check.c +++ b/plugin/password_reuse_check/password_reuse_check.c @@ -51,7 +51,7 @@ static char *store_str(char *to, const MYSQL_CONST_LEX_STRING *from) /** Convert string of 512 bits (64 bytes) to hex representation - @param to pointer to the result puffer + @param to pointer to the result buffer (should be at least 64*2 bytes) @param str pointer to 512 bits (64 bytes string) */ @@ -191,7 +191,7 @@ static int validate(const MYSQL_CONST_LEX_STRING *username, buff[key_len]= 0; // safety memset(hash, 0, sizeof(hash)); my_sha512(hash, buff, key_len); - // safety: rewrite password with zerows + // safety: rewrite password with zeros memset(buff, 0, password->length); if (mysql_real_connect_local(mysql) == NULL) goto sql_error; diff --git a/plugin/query_response_time/query_response_time.h b/plugin/query_response_time/query_response_time.h index dbf4726bb48..956906ffedc 100644 --- a/plugin/query_response_time/query_response_time.h +++ b/plugin/query_response_time/query_response_time.h @@ -32,7 +32,7 @@ */ #define QRT_POSITIVE_POWER_FILLER "" /* - Filler for fractional number. Similiary to whole number + Filler for fractional number. Similarly to whole number */ #define QRT_NEGATIVE_POWER_FILLER "0" diff --git a/plugin/server_audit/server_audit.c b/plugin/server_audit/server_audit.c index 5fc0e3373f3..65e9f0a5314 100644 --- a/plugin/server_audit/server_audit.c +++ b/plugin/server_audit/server_audit.c @@ -2676,7 +2676,7 @@ static int server_audit_init(void *p __attribute__((unused))) PLUGIN_STR_VERSION, PLUGIN_DEBUG_VERSION); /* The Query Cache shadows TABLE events if the result is taken from it */ - /* so we warn users if both Query Cashe and TABLE events enabled. */ + /* so we warn users if both Query Caсhe and TABLE events enabled. */ if (!started_mysql && FILTER(EVENT_TABLE)) { ulonglong *qc_size= (ulonglong *) dlsym(RTLD_DEFAULT, "query_cache_size"); diff --git a/plugin/type_uuid/sql_type_uuid.h b/plugin/type_uuid/sql_type_uuid.h index 2aa190087f8..fa493350350 100644 --- a/plugin/type_uuid/sql_type_uuid.h +++ b/plugin/type_uuid/sql_type_uuid.h @@ -287,7 +287,7 @@ public: /* Convert in-record representation to binlog representation. - We tranfer UUID values in binlog by compressing in-memory representation. + We transfer UUID values in binlog by compressing in-memory representation. This makes replication between UUID and BINARY(16) simpler: Transferring by compressing the in-record representation would require diff --git a/plugin/type_uuid/sql_type_uuid_v7.h b/plugin/type_uuid/sql_type_uuid_v7.h index c9ff8ca35e4..48415e4f5c8 100644 --- a/plugin/type_uuid/sql_type_uuid_v7.h +++ b/plugin/type_uuid/sql_type_uuid_v7.h @@ -72,7 +72,7 @@ class UUIDv7: public Type_handler_uuid_new::Fbt } /* - We have 12 bits for to ensure monotonocity. Let's store microseconds + We have 12 bits to ensure monotonicity. Let's store microseconds there (from 0 to 999) as described in section 6.2, Method 3 of RFC 9562, and use two remaining bits as a counter, thus allowing 4000 UUIDv7 values to be generated within one millisecond. diff --git a/plugin/versioning/versioning.cc b/plugin/versioning/versioning.cc index b4557afc897..9df75aa2f28 100644 --- a/plugin/versioning/versioning.cc +++ b/plugin/versioning/versioning.cc @@ -196,7 +196,7 @@ maria_declare_plugin(versioning) &versioning_plugin, "test_versioning", "MariaDB Corp", - "System Vesioning testing features", + "System Versioning testing features", PLUGIN_LICENSE_GPL, versioning_plugin_init, /* Plugin Init */ versioning_plugin_deinit, /* Plugin Deinit */ diff --git a/sql-common/client.c b/sql-common/client.c index 2d5c6742541..d0d5b290cdc 100644 --- a/sql-common/client.c +++ b/sql-common/client.c @@ -3161,7 +3161,7 @@ CLI_MYSQL_REAL_CONNECT(MYSQL *mysql,const char *host, const char *user, if (mysql->net.last_errno == CR_SERVER_LOST) set_mysql_extended_error(mysql, CR_SERVER_LOST, unknown_sqlstate, ER(CR_SERVER_LOST_EXTENDED), - "Setting intital database", + "Setting initial database", errno); goto error; } diff --git a/sql-common/my_time.c b/sql-common/my_time.c index 3d96695cd5c..fcb10a44cff 100644 --- a/sql-common/my_time.c +++ b/sql-common/my_time.c @@ -1005,7 +1005,7 @@ fractional: else date[4]= 0; - /* Check for exponent part: E | E */ + /* Check for exponent part: E | E */ /* (may occur as result of %g formatting of time value) */ if ((end - str) > 1 && (*str == 'e' || *str == 'E') && diff --git a/strings/ctype-czech.c b/strings/ctype-czech.c index 63ea71451e8..405967cdd06 100644 --- a/strings/ctype-czech.c +++ b/strings/ctype-czech.c @@ -94,7 +94,7 @@ static const uchar *const CZ_SORT_TABLE[] = { }; /* - These define the valuse for the double chars that need to be + These define the values for the double chars that need to be sorted as they were single characters -- in Czech these are 'ch', 'Ch' and 'CH'. */ @@ -396,7 +396,7 @@ static my_bool my_like_range_czech(CHARSET_INFO *cs __attribute__((unused)), { continue; } if (value <= 2) /* End of pass or end of string */ { break; } - if (value == 255) /* Double char too compicated */ + if (value == 255) /* Double char too complicated */ { break; } *min_str++= *max_str++ = *ptr; diff --git a/strings/ctype-mb.c b/strings/ctype-mb.c index 97613e9371e..67c9ab2a087 100644 --- a/strings/ctype-mb.c +++ b/strings/ctype-mb.c @@ -488,7 +488,7 @@ my_strnxfrm_ret_t my_strnxfrm_mb_internal(CHARSET_INFO *cs, } /* - A thourough loop, checking all possible limits: + A thorough loop, checking all possible limits: "se", "nweights" and "de". */ for (; src < se && *nweights && dst < de; (*nweights)--) diff --git a/strings/ctype-simple.c b/strings/ctype-simple.c index d86746a186f..8361df09229 100644 --- a/strings/ctype-simple.c +++ b/strings/ctype-simple.c @@ -1699,7 +1699,7 @@ my_strntoull10rnd_8bit(CHARSET_INFO *cs __attribute__((unused)), ul= ul * 10 + ch; } - if (str >= end) /* Small number without dots and expanents */ + if (str >= end) /* Small number without dots and exponents */ { *endptr= (char*) str; if (negative) @@ -2074,7 +2074,7 @@ uint my_strxfrm_flag_normalize(CHARSET_INFO *cs, uint flags) reverse order for that level, that is, starting with the last character and ending with the first character. - If nether DESC nor REVERSE flags are give, + If neither DESC nor REVERSE flags are give, the string is not changed. */ diff --git a/strings/ctype-tis620.c b/strings/ctype-tis620.c index b855c331ab3..5b0fba39aa7 100644 --- a/strings/ctype-tis620.c +++ b/strings/ctype-tis620.c @@ -609,7 +609,7 @@ int my_strnncollsp_tis620_nopad(CHARSET_INFO * cs __attribute__((unused)), return my_strnncoll_tis620(cs, a0, a_length, b0, b_length, FALSE); } /* - strnxfrm replacment, convert Thai string to sortable string + strnxfrm replacement, convert Thai string to sortable string Arg: Destination buffer, source string, dest length and source length Ret: Converted string size diff --git a/strings/ctype-uca.c b/strings/ctype-uca.c index 90568eaff00..f2bbc70f40b 100644 --- a/strings/ctype-uca.c +++ b/strings/ctype-uca.c @@ -28,7 +28,7 @@ Features that are not implemented yet: - No Normalization From D is done + No decomposition is done - + No Thai/Lao orderding is done + + No Thai/Lao ordering is done - No combining marks processing is done */ @@ -32274,7 +32274,7 @@ my_uca_collation_can_optimize_no_contractions(CHARSET_INFO *cs) Diff command: := < - Identifies a primary difference. := << - Identifies a secondary difference. - := <<< - Idenfifies a tertiary difference. + := <<< - Identifies a tertiary difference. Collation rules: @@ -32352,7 +32352,7 @@ typedef struct my_coll_lexem_st /* - Initialize collation rule lexical anilizer + Initialize collation rule lexical analyzer SYNOPSIS my_coll_lexem_init @@ -32703,7 +32703,7 @@ my_coll_rule_reset(MY_COLL_RULE *r) /* Shift methods: Simple: "&B < C" : weight('C') = weight('B') + 1 - Expand: weght('C') = { weight('B'), weight(last_non_ignorable) + 1 } + Expand: weight('C') = { weight('B'), weight(last_non_ignorable) + 1 } */ typedef enum { @@ -33353,7 +33353,7 @@ my_coll_parser_scan_rule(MY_COLL_RULE_PARSER *p) @param p Collation customization parser @return - @retval 0 if collation customozation expression was not scanned. + @retval 0 if collation customization expression was not scanned. @retval 1 if collation customization expression was scanned. */ @@ -33562,7 +33562,7 @@ apply_shift(MY_CHARSET_LOADER *loader, 'a' must be sorted before 'A'. Note, there are no real collations in CLDR which shift - after and before two neighbourgh characters. We need this + after and before two adjacent characters. We need this just in case. Reserving 4096 (0x1000) weights for such cases is perfectly enough. */ @@ -34243,7 +34243,7 @@ my_uca_level_booster_2bytes_disable_context_dependent( 2 (two ASCII chars) 0 (both ignorable) {0,0} [IGN] 2 (two ASCII chars) 1 (e.g. Czech "ch") {X,0} 2 (two ASCII chars) 1 (e.g. ignorable + non-ignorable) {X,0} - 2 (two ASCII chars) 2 (two ASCII chars, one weigth each) {X,0} + 2 (two ASCII chars) 2 (two ASCII chars, one weight each) {X,0} 2 (two ASCII chars) 3+ (contraction with a long expansion) {0,0} [E3] 1 (one 2-byte char) 0 (ignorable) {0,0} [IGN] 1 (one 2-byte char) 1 {X,0} diff --git a/strings/ctype-utf16.h b/strings/ctype-utf16.h index d4cf4664f97..4a96cec6bc5 100644 --- a/strings/ctype-utf16.h +++ b/strings/ctype-utf16.h @@ -63,7 +63,7 @@ my_mb_wc_utf16_quick(my_wc_t *pwc, const uchar *s, const uchar *e) if (s + 4 > e) return MY_CS_TOOSMALL4; - if (!MY_UTF16_LOW_HEAD(s[2])) /* Broken surrigate pair */ + if (!MY_UTF16_LOW_HEAD(s[2])) /* Broken surrogate pair */ return MY_CS_ILSEQ; *pwc= MY_UTF16_WC4(s[0], s[1], s[2], s[3]); diff --git a/strings/ctype-utf8.c b/strings/ctype-utf8.c index 0e1a756d296..c87de651147 100644 --- a/strings/ctype-utf8.c +++ b/strings/ctype-utf8.c @@ -1229,7 +1229,7 @@ struct charset_info_st my_charset_utf8mb3_nopad_bin= #ifdef HAVE_UTF8_GENERAL_CS /* - * These functions bacically do the same as their original, except + * These functions basically do the same as their original, except * that they return 0 only when two comparing unicode strings are * strictly the same in case-sensitive way. See "save_diff" local * variable to what they actually do. @@ -1329,7 +1329,7 @@ static int my_strnncollsp_utf8mb3_cs(CHARSET_INFO *cs, space. It means if we meet a character greater than space, it always means that the longer string is greater. So we can reuse the same loop from the - 8bit version, without having to process full multibute + 8bit version, without having to process full multibyte sequences. */ if ((res= slen == tlen ? 0 : diff --git a/strings/decimal.c b/strings/decimal.c index 7d4e183ef63..2d729346255 100644 --- a/strings/decimal.c +++ b/strings/decimal.c @@ -17,7 +17,7 @@ /* ======================================================================= NOTE: this library implements SQL standard "exact numeric" type - and is not at all generic, but rather intentinally crippled to + and is not at all generic, but rather intentionally crippled to follow the standard :) ======================================================================= Quoting the standard @@ -579,12 +579,12 @@ void do_mini_right_shift(decimal_t *dec, int shift, int beg, int last) dec number to be shifted shift number of decimal positions shift > 0 means shift to left shift - shift < 0 meand right shift + shift < 0 means right shift NOTE - In fact it is multipling on 10^shift. + In fact it is multiplying on 10^shift. RETURN E_DEC_OK OK - E_DEC_OVERFLOW operation lead to overflow, number is untoched + E_DEC_OVERFLOW operation lead to overflow, number is untouched E_DEC_TRUNCATED number was rounded to fit into buffer */ diff --git a/strings/do_ctype.c b/strings/do_ctype.c index e9430deee42..bea9cb8df22 100644 --- a/strings/do_ctype.c +++ b/strings/do_ctype.c @@ -91,7 +91,7 @@ register char **argv[]; break; case '#': DBUG_PUSH (++pos); - *(pos--) = '\0'; /* Skippa argument */ + *(pos--) = '\0'; /* Skip argument */ break; case 'V': version=1; @@ -164,7 +164,7 @@ void init_case_convert() to_lower[ *higher_pos++ ] = (char) *lower_pos++; } - /* sets upp sortorder; higer_pos character (upper and lower) is */ + /* sets up sortorder; higher_pos character (upper and lower) is */ /* changed to lower_pos character */ #if defined(HPUX10) diff --git a/strings/dtoa.c b/strings/dtoa.c index 21eb95479da..9cee85d4961 100644 --- a/strings/dtoa.c +++ b/strings/dtoa.c @@ -242,7 +242,7 @@ size_t my_gcvt(double x, my_gcvt_arg_type type, int width, char *to, /* Number of digits in the exponent from the 'e' conversion. - The sign of the exponent is taken into account separetely, we don't need + The sign of the exponent is taken into account separately, we don't need to count it here. */ exp_len= 1 + (decpt >= 101 || decpt <= -99) + (decpt >= 11 || decpt <= -9); diff --git a/strings/xml.c b/strings/xml.c index 7260ecadc66..9f2f6b4651c 100644 --- a/strings/xml.c +++ b/strings/xml.c @@ -429,7 +429,7 @@ int my_xml_parse(MY_XML_PARSER *p,const char *str, size_t len) /* We are in , e.g. - + Just skip "SystemLiteral" and "PublicidLiteral" */ } diff --git a/tests/mysql_client_fw.c b/tests/mysql_client_fw.c index 9f0faf85021..5bd48a0dddc 100644 --- a/tests/mysql_client_fw.c +++ b/tests/mysql_client_fw.c @@ -121,7 +121,7 @@ static void get_options(int *argc, char ***argv); /* - Abort unless given experssion is non-zero. + Abort unless given expression is non-zero. SYNOPSIS DIE_UNLESS(expr) diff --git a/tests/mysql_client_test.c b/tests/mysql_client_test.c index b131b9817ed..b4df95f8988 100644 --- a/tests/mysql_client_test.c +++ b/tests/mysql_client_test.c @@ -7861,7 +7861,7 @@ static void test_explain_bug() if ( mysql_get_server_version(mysql) >= 50027 ) { - /* The patch for bug#23037 changes column type of DEAULT to blob */ + /* The patch for bug#23037 changes column type of DEFAULT to blob */ verify_prepare_field(result, 4, "Default", "COLUMN_DEFAULT", MYSQL_TYPE_BLOB, 0, 0, "information_schema", 0, 0); } @@ -13779,7 +13779,7 @@ static void test_bug8722() myquery(rc); /* Note: if you uncomment following block everything works fine */ /* - rc= mysql_query(mysql, "sellect * from v1"); + rc= mysql_query(mysql, "select * from v1"); myquery(rc); mysql_free_result(mysql_store_result(mysql)); */ @@ -13917,7 +13917,7 @@ static void test_bug9159() } -/* Crash when opening a cursor to a query with DISTICNT and no key */ +/* Crash when opening a cursor to a query with DISTINCT and no key */ static void test_bug9520() { @@ -14233,7 +14233,7 @@ static void test_bug11111() /* Check that proper cleanups are done for prepared statement when - fetching thorugh a cursor. + fetching through a cursor. */ static void test_bug10729() @@ -15052,7 +15052,7 @@ static void test_bug11909() myquery(rc); } -/* Cursors: opening a cursor to a compilicated query with ORDER BY */ +/* Cursors: opening a cursor to a complicated query with ORDER BY */ static void test_bug11901() { @@ -15927,7 +15927,7 @@ static void test_bug17667() char line_buffer[MAX_TEST_QUERY_LENGTH*2]; /* more than enough room for the query and some marginalia. */ - /* Prepared statments always occurs twice in log */ + /* Prepared statements always occurs twice in log */ if (statement_cursor->qt == QT_PREPARED) expected_hits++; diff --git a/tests/prev_record.cc b/tests/prev_record.cc index 66fe8e6a464..e28de5ba28c 100644 --- a/tests/prev_record.cc +++ b/tests/prev_record.cc @@ -111,7 +111,7 @@ prev_record_reads(POSITION *position, uint idx, DEPEND found_ref, { found_ref&= ~pos->table->map; - /* Found depent table */ + /* Found dependent table */ if (pos->type == EQ_REF) { if (!found_ref) @@ -127,8 +127,8 @@ prev_record_reads(POSITION *position, uint idx, DEPEND found_ref, if (pos->type != CACHE) { /* - We are not depending on the curren table - There are 'records_out' rows with idenitical rows + We are not depending on the current table + There are 'records_out' rows with identical rows value for our depending tables. We are ignoring join_cache as in this case the preceding tables row combination can change for diff --git a/tpool/tpool_generic.cc b/tpool/tpool_generic.cc index 18148d4d99c..93d0c4a5dd1 100644 --- a/tpool/tpool_generic.cc +++ b/tpool/tpool_generic.cc @@ -261,10 +261,10 @@ class thread_pool_generic : public thread_pool /** Last time thread was created*/ std::chrono::system_clock::time_point m_last_thread_creation; - /** Minimumum number of threads in this pool.*/ + /** Minimum number of threads in this pool.*/ unsigned int m_min_threads; - /** Maximimum number of threads in this pool. */ + /** Maximum number of threads in this pool. */ unsigned int m_max_threads; /* maintenance related statistics (see maintenance()) */ @@ -371,7 +371,7 @@ public: { if (pool) { - /* EXecute callback in threadpool*/ + /* Execute callback in threadpool*/ thr_timer_init(this, submit_task, this); } else @@ -951,7 +951,7 @@ thread_pool_generic::~thread_pool_generic() */ m_aio.reset(); - /* Also stop the maintanence task early. */ + /* Also stop the maintenance task early. */ if (m_maintenance_timer) m_maintenance_timer->disarm(); diff --git a/unittest/mysys/stacktrace-t.c b/unittest/mysys/stacktrace-t.c index c8b699ca696..0addbca6f49 100644 --- a/unittest/mysys/stacktrace-t.c +++ b/unittest/mysys/stacktrace-t.c @@ -41,7 +41,7 @@ void test_my_safe_print_str() my_safe_print_str("LEGAL", 65535); fprintf(stderr, "\n===== Above is a junk, but it is expected. =====\n"); # endif - fprintf(stderr, "\n===== Nornal length test =====\n"); + fprintf(stderr, "\n===== Normal length test =====\n"); my_safe_print_str("LEGAL", 5); fprintf(stderr, "\n===== NULL =====\n"); my_safe_print_str(0, 5); diff --git a/unittest/mytap/tap.c b/unittest/mytap/tap.c index d8c0f7d94de..085da02c9c5 100644 --- a/unittest/mytap/tap.c +++ b/unittest/mytap/tap.c @@ -470,7 +470,7 @@ static void end_timer(ulong start_time,char *buff) This is to test that the component have the expected behaviour. This is just plain simple: test that it works. For example, test - that you can unpack what you packed, adding gives the sum, pincing + that you can unpack what you packed, adding gives the sum, pinching the duck makes it quack. This is what everybody does when they write tests. @@ -630,7 +630,7 @@ static void end_timer(ulong start_time,char *buff) @subsection JustToBeSafeTest Writing unnecessarily large tests Don't write tests that use parameters in the range 1-1024 unless - you have a very good reason to belive that the component will + you have a very good reason to believe that the component will succeed for 562 but fail for 564 (the numbers picked are just examples). diff --git a/unittest/sql/mf_iocache-t.cc b/unittest/sql/mf_iocache-t.cc index 668c30d918a..39de40c914f 100644 --- a/unittest/sql/mf_iocache-t.cc +++ b/unittest/sql/mf_iocache-t.cc @@ -414,7 +414,7 @@ void mdev10963() */ for (; n_checks; n_checks--, rewind(file)) { - // copied size is an estimate can be incremeneted to greater than total_size + // copied size is an estimate can be incremented to greater than total_size ulong copied_size= 0; res= reinit_io_cache(&info, READ_CACHE, 0L, FALSE, FALSE); diff --git a/vio/viossl.c b/vio/viossl.c index 6fdebca1874..52e3e42de23 100644 --- a/vio/viossl.c +++ b/vio/viossl.c @@ -216,7 +216,7 @@ int vio_ssl_close(Vio *vio) alert on socket shutdown to avoid truncation attacks. However, this can cause problems since we often hold a lock during shutdown and this IO can take an unbounded amount of time to complete. Since our packets are self - describing with length, we aren't vunerable to these attacks. Therefore, + describing with length, we aren't vulnerable to these attacks. Therefore, we just shutdown by closing the socket (quiet shutdown). */ SSL_set_quiet_shutdown(ssl, 1); diff --git a/win/packaging/ca/CustomAction.cpp b/win/packaging/ca/CustomAction.cpp index c397ce234fd..3551eb3a77a 100644 --- a/win/packaging/ca/CustomAction.cpp +++ b/win/packaging/ca/CustomAction.cpp @@ -341,7 +341,7 @@ static bool IsPortInUse(unsigned short port) /* Prefer IPv6 socket to IPv4, since we'll use IPv6 dual socket, - which coveres both IP versions. + which covers both IP versions. */ for (a = ai; a; a = a->ai_next) {