diff --git a/src/ae.c b/src/ae.c index 689a27d16a..c516665620 100644 --- a/src/ae.c +++ b/src/ae.c @@ -457,7 +457,7 @@ int aeProcessEvents(aeEventLoop *eventLoop, int flags) int fired = 0; /* Number of events fired for current fd. */ /* Normally we execute the readable event first, and the writable - * event laster. This is useful as sometimes we may be able + * event later. This is useful as sometimes we may be able * to serve the reply of a query immediately after processing the * query. * @@ -465,7 +465,7 @@ int aeProcessEvents(aeEventLoop *eventLoop, int flags) * asking us to do the reverse: never fire the writable event * after the readable. In such a case, we invert the calls. * This is useful when, for instance, we want to do things - * in the beforeSleep() hook, like fsynching a file to disk, + * in the beforeSleep() hook, like fsyncing a file to disk, * before replying to a client. */ int invert = fe->mask & AE_BARRIER; diff --git a/src/aof.c b/src/aof.c index cbc0989d0e..c3dde57e16 100644 --- a/src/aof.c +++ b/src/aof.c @@ -1818,7 +1818,7 @@ void backgroundRewriteDoneHandler(int exitcode, int bysignal) { "Background AOF rewrite terminated with error"); } else { /* SIGUSR1 is whitelisted, so we have a way to kill a child without - * tirggering an error condition. */ + * triggering an error condition. */ if (bysignal != SIGUSR1) server.aof_lastbgrewrite_status = C_ERR; diff --git a/src/atomicvar.h b/src/atomicvar.h index 160056cd7c..ecd26ad701 100644 --- a/src/atomicvar.h +++ b/src/atomicvar.h @@ -21,7 +21,7 @@ * * Never use return value from the macros, instead use the AtomicGetIncr() * if you need to get the current value and increment it atomically, like - * in the followign example: + * in the following example: * * long oldvalue; * atomicGetIncr(myvar,oldvalue,1); diff --git a/src/bitops.c b/src/bitops.c index 37fb13f0c6..689a6acf5a 100644 --- a/src/bitops.c +++ b/src/bitops.c @@ -496,7 +496,7 @@ robj *lookupStringForBitCommand(client *c, size_t maxbit) { * in 'len'. The user is required to pass (likely stack allocated) buffer * 'llbuf' of at least LONG_STR_SIZE bytes. Such a buffer is used in the case * the object is integer encoded in order to provide the representation - * without usign heap allocation. + * without using heap allocation. * * The function returns the pointer to the object array of bytes representing * the string it contains, that may be a pointer to 'llbuf' or to the diff --git a/src/cluster.c b/src/cluster.c index ba0ada04a3..b828e7f28f 100644 --- a/src/cluster.c +++ b/src/cluster.c @@ -377,7 +377,7 @@ void clusterSaveConfigOrDie(int do_fsync) { } } -/* Lock the cluster config using flock(), and leaks the file descritor used to +/* Lock the cluster config using flock(), and leaks the file descriptor used to * acquire the lock so that the file will be locked forever. * * This works because we always update nodes.conf with a new version @@ -1060,7 +1060,7 @@ uint64_t clusterGetMaxEpoch(void) { * 3) Persist the configuration on disk before sending packets with the * new configuration. * - * If the new config epoch is generated and assigend, C_OK is returned, + * If the new config epoch is generated and assigned, C_OK is returned, * otherwise C_ERR is returned (since the node has already the greatest * configuration around) and no operation is performed. * @@ -2500,7 +2500,7 @@ void clusterSendPing(clusterLink *link, int type) { * node_timeout we exchange with each other node at least 4 packets * (we ping in the worst case in node_timeout/2 time, and we also * receive two pings from the host), we have a total of 8 packets - * in the node_timeout*2 falure reports validity time. So we have + * in the node_timeout*2 failure reports validity time. So we have * that, for a single PFAIL node, we can expect to receive the following * number of failure reports (in the specified window of time): * @@ -4507,7 +4507,7 @@ NULL } /* If this slot is in migrating status but we have no keys * for it assigning the slot to another node will clear - * the migratig status. */ + * the migrating status. */ if (countKeysInSlot(slot) == 0 && server.cluster->migrating_slots_to[slot]) server.cluster->migrating_slots_to[slot] = NULL; diff --git a/src/cluster.h b/src/cluster.h index 596a4629ad..7eaceb2212 100644 --- a/src/cluster.h +++ b/src/cluster.h @@ -52,7 +52,7 @@ typedef struct clusterLink { #define CLUSTER_NODE_NOADDR 64 /* We don't know the address of this node */ #define CLUSTER_NODE_MEET 128 /* Send a MEET message to this node */ #define CLUSTER_NODE_MIGRATE_TO 256 /* Master elegible for replica migration. */ -#define CLUSTER_NODE_NOFAILOVER 512 /* Slave will not try to failver. */ +#define CLUSTER_NODE_NOFAILOVER 512 /* Slave will not try to failover. */ #define CLUSTER_NODE_NULL_NAME "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000" #define nodeIsMaster(n) ((n)->flags & CLUSTER_NODE_MASTER) @@ -164,7 +164,7 @@ typedef struct clusterState { clusterNode *mf_slave; /* Slave performing the manual failover. */ /* Manual failover state of slave. */ long long mf_master_offset; /* Master offset the slave needs to start MF - or zero if stil not received. */ + or zero if still not received. */ int mf_can_start; /* If non-zero signal that the manual failover can start requesting masters vote. */ /* The followign fields are used by masters to take state on elections. */ diff --git a/src/config.c b/src/config.c index 5b73d9e28d..b2295c5106 100644 --- a/src/config.c +++ b/src/config.c @@ -2108,7 +2108,7 @@ static int updateJemallocBgThread(int val, int prev, char **err) { static int updateReplBacklogSize(long long val, long long prev, char **err) { /* resizeReplicationBacklog sets server.repl_backlog_size, and relies on - * being able to tell when the size changes, so restore prev becore calling it. */ + * being able to tell when the size changes, so restore prev before calling it. */ UNUSED(err); server.repl_backlog_size = prev; resizeReplicationBacklog(val); diff --git a/src/connection.h b/src/connection.h index 85585a3d03..e00d2ea178 100644 --- a/src/connection.h +++ b/src/connection.h @@ -106,7 +106,7 @@ static inline int connAccept(connection *conn, ConnectionCallbackFunc accept_han } /* Establish a connection. The connect_handler will be called when the connection - * is established, or if an error has occured. + * is established, or if an error has occurred. * * The connection handler will be responsible to set up any read/write handlers * as needed. @@ -168,7 +168,7 @@ static inline int connSetReadHandler(connection *conn, ConnectionCallbackFunc fu /* Set a write handler, and possibly enable a write barrier, this flag is * cleared when write handler is changed or removed. - * With barroer enabled, we never fire the event if the read handler already + * With barrier enabled, we never fire the event if the read handler already * fired in the same event loop iteration. Useful when you want to persist * things to disk before sending replies, and want to do that in a group fashion. */ static inline int connSetWriteHandlerWithBarrier(connection *conn, ConnectionCallbackFunc func, int barrier) { diff --git a/src/db.c b/src/db.c index 70de568fb4..fe575d5a0f 100644 --- a/src/db.c +++ b/src/db.c @@ -116,7 +116,7 @@ robj *lookupKeyReadWithFlags(redisDb *db, robj *key, int flags) { * However, if the command caller is not the master, and as additional * safety measure, the command invoked is a read-only command, we can * safely return NULL here, and provide a more consistent behavior - * to clients accessign expired values in a read-only fashion, that + * to clients accessing expired values in a read-only fashion, that * will say the key as non existing. * * Notably this covers GETs when slaves are used to scale reads. */ diff --git a/src/debug.c b/src/debug.c index 5cfda59c9f..a600e0af07 100644 --- a/src/debug.c +++ b/src/debug.c @@ -465,7 +465,7 @@ NULL } } - /* The default beahvior is to save the RDB file before loading + /* The default behavior is to save the RDB file before loading * it back. */ if (save) { rdbSaveInfo rsi, *rsiptr; diff --git a/src/dict.c b/src/dict.c index a26ef18d35..8b4bc6e5f8 100644 --- a/src/dict.c +++ b/src/dict.c @@ -751,7 +751,7 @@ unsigned int dictGetSomeKeys(dict *d, dictEntry **des, unsigned int count) { * this function instead what we do is to consider a "linear" range of the table * that may be constituted of N buckets with chains of different lengths * appearing one after the other. Then we report a random element in the range. - * In this way we smooth away the problem of different chain lenghts. */ + * In this way we smooth away the problem of different chain lengths. */ #define GETFAIR_NUM_ENTRIES 15 dictEntry *dictGetFairRandomKey(dict *d) { dictEntry *entries[GETFAIR_NUM_ENTRIES]; @@ -1121,7 +1121,7 @@ size_t _dictGetStatsHt(char *buf, size_t bufsize, dictht *ht, int tableid) { i, clvector[i], ((float)clvector[i]/ht->size)*100); } - /* Unlike snprintf(), teturn the number of characters actually written. */ + /* Unlike snprintf(), return the number of characters actually written. */ if (bufsize) buf[bufsize-1] = '\0'; return strlen(buf); } diff --git a/src/endianconv.c b/src/endianconv.c index f3b0b47308..918844e25b 100644 --- a/src/endianconv.c +++ b/src/endianconv.c @@ -8,7 +8,7 @@ * to be backward compatible are still in big endian) because most of the * production environments are little endian, and we have a lot of conversions * in a few places because ziplists, intsets, zipmaps, need to be endian-neutral - * even in memory, since they are serialied on RDB files directly with a single + * even in memory, since they are serialized on RDB files directly with a single * write(2) without other additional steps. * * ---------------------------------------------------------------------------- diff --git a/src/evict.c b/src/evict.c index 0755acc0ef..b6560af1be 100644 --- a/src/evict.c +++ b/src/evict.c @@ -242,7 +242,7 @@ void evictionPoolPopulate(int dbid, dict *sampledict, dict *keydict, struct evic /* Try to reuse the cached SDS string allocated in the pool entry, * because allocating and deallocating this object is costly * (according to the profiler, not my fantasy. Remember: - * premature optimizbla bla bla bla. */ + * premature optimize bla bla bla. */ int klen = sdslen(key); if (klen > EVPOOL_CACHED_SDS_SIZE) { pool[k].key = sdsdup(key); @@ -342,7 +342,7 @@ unsigned long LFUDecrAndReturn(robj *o) { } /* ---------------------------------------------------------------------------- - * The external API for eviction: freeMemroyIfNeeded() is called by the + * The external API for eviction: freeMemoryIfNeeded() is called by the * server when there is data to add in order to make space if needed. * --------------------------------------------------------------------------*/ @@ -441,7 +441,7 @@ int getMaxmemoryState(size_t *total, size_t *logical, size_t *tofree, float *lev * * The function returns C_OK if we are under the memory limit or if we * were over the limit, but the attempt to free memory was successful. - * Otehrwise if we are over the memory limit, but not enough memory + * Otherwise if we are over the memory limit, but not enough memory * was freed to return back under the limit, the function returns C_ERR. */ int freeMemoryIfNeeded(void) { int keys_freed = 0; diff --git a/src/expire.c b/src/expire.c index 1c4f71df33..9c24d6f5b6 100644 --- a/src/expire.c +++ b/src/expire.c @@ -414,7 +414,7 @@ void expireSlaveKeys(void) { else dictDelete(slaveKeysWithExpire,keyname); - /* Stop conditions: found 3 keys we cna't expire in a row or + /* Stop conditions: found 3 keys we can't expire in a row or * time limit was reached. */ cycles++; if (noexpire > 3) break; @@ -466,7 +466,7 @@ size_t getSlaveKeyWithExpireCount(void) { * * Note: technically we should handle the case of a single DB being flushed * but it is not worth it since anyway race conditions using the same set - * of key names in a wriatable slave and in its master will lead to + * of key names in a writeable slave and in its master will lead to * inconsistencies. This is just a best-effort thing we do. */ void flushSlaveKeysWithExpireList(void) { if (slaveKeysWithExpire) { @@ -490,7 +490,7 @@ int checkAlreadyExpired(long long when) { *----------------------------------------------------------------------------*/ /* This is the generic command implementation for EXPIRE, PEXPIRE, EXPIREAT - * and PEXPIREAT. Because the commad second argument may be relative or absolute + * and PEXPIREAT. Because the command second argument may be relative or absolute * the "basetime" argument is used to signal what the base time is (either 0 * for *AT variants of the command, or the current time for relative expires). * diff --git a/src/geo.c b/src/geo.c index 77f07637ab..efbd950912 100644 --- a/src/geo.c +++ b/src/geo.c @@ -144,7 +144,7 @@ double extractUnitOrReply(client *c, robj *unit) { /* Input Argument Helper. * Extract the dinstance from the specified two arguments starting at 'argv' - * that shouldbe in the form: and return the dinstance in the + * that shouldbe in the form: and return the distance in the * specified unit on success. *conversions is populated with the coefficient * to use in order to convert meters to the unit. * @@ -788,7 +788,7 @@ void geoposCommand(client *c) { /* GEODIST key ele1 ele2 [unit] * - * Return the distance, in meters by default, otherwise accordig to "unit", + * Return the distance, in meters by default, otherwise according to "unit", * between points ele1 and ele2. If one or more elements are missing NULL * is returned. */ void geodistCommand(client *c) { diff --git a/src/hyperloglog.c b/src/hyperloglog.c index 721f492a18..a2c49f7f04 100644 --- a/src/hyperloglog.c +++ b/src/hyperloglog.c @@ -766,7 +766,7 @@ int hllSparseSet(robj *o, long index, uint8_t count) { * by a ZERO opcode with len > 1, or by an XZERO opcode. * * In those cases the original opcode must be split into multiple - * opcodes. The worst case is an XZERO split in the middle resuling into + * opcodes. The worst case is an XZERO split in the middle resulting into * XZERO - VAL - XZERO, so the resulting sequence max length is * 5 bytes. * @@ -899,7 +899,7 @@ promote: /* Promote to dense representation. */ * the element belongs to is incremented if needed. * * This function is actually a wrapper for hllSparseSet(), it only performs - * the hashshing of the elmenet to obtain the index and zeros run length. */ + * the hashshing of the element to obtain the index and zeros run length. */ int hllSparseAdd(robj *o, unsigned char *ele, size_t elesize) { long index; uint8_t count = hllPatLen(ele,elesize,&index); @@ -1014,7 +1014,7 @@ uint64_t hllCount(struct hllhdr *hdr, int *invalid) { double m = HLL_REGISTERS; double E; int j; - /* Note that reghisto size could be just HLL_Q+2, becuase HLL_Q+1 is + /* Note that reghisto size could be just HLL_Q+2, because HLL_Q+1 is * the maximum frequency of the "000...1" sequence the hash function is * able to return. However it is slow to check for sanity of the * input: instead we history array at a safe size: overflows will diff --git a/src/latency.c b/src/latency.c index dfdc6668cf..77e4693ff1 100644 --- a/src/latency.c +++ b/src/latency.c @@ -85,7 +85,7 @@ int THPGetAnonHugePagesSize(void) { /* ---------------------------- Latency API --------------------------------- */ /* Latency monitor initialization. We just need to create the dictionary - * of time series, each time serie is created on demand in order to avoid + * of time series, each time series is created on demand in order to avoid * having a fixed list to maintain. */ void latencyMonitorInit(void) { server.latency_events = dictCreate(&latencyTimeSeriesDictType,NULL); diff --git a/src/lazyfree.c b/src/lazyfree.c index f01504e707..754fbb47d8 100644 --- a/src/lazyfree.c +++ b/src/lazyfree.c @@ -15,7 +15,7 @@ size_t lazyfreeGetPendingObjectsCount(void) { /* Return the amount of work needed in order to free an object. * The return value is not always the actual number of allocations the - * object is compoesd of, but a number proportional to it. + * object is composed of, but a number proportional to it. * * For strings the function always returns 1. * @@ -113,7 +113,7 @@ void emptyDbAsync(redisDb *db) { } /* Empty the slots-keys map of Redis CLuster by creating a new empty one - * and scheduiling the old for lazy freeing. */ + * and scheduling the old for lazy freeing. */ void slotToKeyFlushAsync(void) { rax *old = server.cluster->slots_to_keys; @@ -132,7 +132,7 @@ void lazyfreeFreeObjectFromBioThread(robj *o) { } /* Release a database from the lazyfree thread. The 'db' pointer is the - * database which was substitutied with a fresh one in the main thread + * database which was substituted with a fresh one in the main thread * when the database was logically deleted. 'sl' is a skiplist used by * Redis Cluster in order to take the hash slots -> keys mapping. This * may be NULL if Redis Cluster is disabled. */ diff --git a/src/lolwut.c b/src/lolwut.c index 0e1552ba04..01a9827aa3 100644 --- a/src/lolwut.c +++ b/src/lolwut.c @@ -106,7 +106,7 @@ void lwFreeCanvas(lwCanvas *canvas) { } /* Set a pixel to the specified color. Color is 0 or 1, where zero means no - * dot will be displyed, and 1 means dot will be displayed. + * dot will be displayed, and 1 means dot will be displayed. * Coordinates are arranged so that left-top corner is 0,0. You can write * out of the size of the canvas without issues. */ void lwDrawPixel(lwCanvas *canvas, int x, int y, int color) { diff --git a/src/module.c b/src/module.c index 2c90c599a6..e66a01023a 100644 --- a/src/module.c +++ b/src/module.c @@ -46,7 +46,7 @@ typedef struct RedisModuleInfoCtx { sds info; /* info string we collected so far */ int sections; /* number of sections we collected so far */ int in_section; /* indication if we're in an active section or not */ - int in_dict_field; /* indication that we're curreintly appending to a dict */ + int in_dict_field; /* indication that we're currently appending to a dict */ } RedisModuleInfoCtx; typedef void (*RedisModuleInfoFunc)(RedisModuleInfoCtx *ctx, int for_crash_report); @@ -1920,7 +1920,7 @@ int RM_GetContextFlags(RedisModuleCtx *ctx) { flags |= REDISMODULE_CTX_FLAGS_LUA; if (ctx->client->flags & CLIENT_MULTI) flags |= REDISMODULE_CTX_FLAGS_MULTI; - /* Module command recieved from MASTER, is replicated. */ + /* Module command received from MASTER, is replicated. */ if (ctx->client->flags & CLIENT_MASTER) flags |= REDISMODULE_CTX_FLAGS_REPLICATED; } @@ -3629,7 +3629,7 @@ void moduleTypeNameByID(char *name, uint64_t moduleid) { * and if the module name or encver is invalid, NULL is returned. * Otherwise the new type is registered into Redis, and a reference of * type RedisModuleType is returned: the caller of the function should store - * this reference into a gobal variable to make future use of it in the + * this reference into a global variable to make future use of it in the * modules type API, since a single module may register multiple types. * Example code fragment: * @@ -3768,7 +3768,7 @@ int moduleAllDatatypesHandleErrors() { /* Returns true if any previous IO API failed. * for Load* APIs the REDISMODULE_OPTIONS_HANDLE_IO_ERRORS flag must be set with - * RediModule_SetModuleOptions first. */ + * RedisModule_SetModuleOptions first. */ int RM_IsIOError(RedisModuleIO *io) { return io->error; } @@ -3901,7 +3901,7 @@ RedisModuleString *RM_LoadString(RedisModuleIO *io) { * * The size of the string is stored at '*lenptr' if not NULL. * The returned string is not automatically NULL terminated, it is loaded - * exactly as it was stored inisde the RDB file. */ + * exactly as it was stored inside the RDB file. */ char *RM_LoadStringBuffer(RedisModuleIO *io, size_t *lenptr) { return moduleLoadString(io,1,lenptr); } @@ -4900,7 +4900,7 @@ void moduleReleaseGIL(void) { /* Subscribe to keyspace notifications. This is a low-level version of the * keyspace-notifications API. A module can register callbacks to be notified - * when keyspce events occur. + * when keyspace events occur. * * Notification events are filtered by their type (string events, set events, * etc), and the subscriber callback receives only events that match a specific @@ -5611,7 +5611,7 @@ int RM_AuthenticateClientWithACLUser(RedisModuleCtx *ctx, const char *name, size /* Deauthenticate and close the client. The client resources will not be * be immediately freed, but will be cleaned up in a background job. This is * the recommended way to deauthenicate a client since most clients can't - * handle users becomming deauthenticated. Returns REDISMODULE_ERR when the + * handle users becoming deauthenticated. Returns REDISMODULE_ERR when the * client doesn't exist and REDISMODULE_OK when the operation was successful. * * The client ID is returned from the RM_AuthenticateClientWithUser and @@ -5731,14 +5731,14 @@ int RM_DictDel(RedisModuleDict *d, RedisModuleString *key, void *oldval) { return RM_DictDelC(d,key->ptr,sdslen(key->ptr),oldval); } -/* Return an interator, setup in order to start iterating from the specified +/* Return an iterator, setup in order to start iterating from the specified * key by applying the operator 'op', which is just a string specifying the * comparison operator to use in order to seek the first element. The - * operators avalable are: + * operators available are: * * "^" -- Seek the first (lexicographically smaller) key. * "$" -- Seek the last (lexicographically biffer) key. - * ">" -- Seek the first element greter than the specified key. + * ">" -- Seek the first element greater than the specified key. * ">=" -- Seek the first element greater or equal than the specified key. * "<" -- Seek the first element smaller than the specified key. * "<=" -- Seek the first element smaller or equal than the specified key. @@ -5865,7 +5865,7 @@ RedisModuleString *RM_DictPrev(RedisModuleCtx *ctx, RedisModuleDictIter *di, voi * in the loop, as we iterate elements, we can also check if we are still * on range. * - * The function returne REDISMODULE_ERR if the iterator reached the + * The function return REDISMODULE_ERR if the iterator reached the * end of elements condition as well. */ int RM_DictCompareC(RedisModuleDictIter *di, const char *op, void *key, size_t keylen) { if (raxEOF(&di->ri)) return REDISMODULE_ERR; @@ -6246,7 +6246,7 @@ int RM_ExportSharedAPI(RedisModuleCtx *ctx, const char *apiname, void *func) { * command that requires external APIs: if some API cannot be resolved, the * command should return an error. * - * Here is an exmaple: + * Here is an example: * * int ... myCommandImplementation() { * if (getExternalAPIs() == 0) { @@ -6632,7 +6632,7 @@ void RM_ScanCursorDestroy(RedisModuleScanCursor *cursor) { * RedisModule_ScanCursorDestroy(c); * * It is also possible to use this API from another thread while the lock - * is acquired durring the actuall call to RM_Scan: + * is acquired during the actuall call to RM_Scan: * * RedisModuleCursor *c = RedisModule_ScanCursorCreate(); * RedisModule_ThreadSafeContextLock(ctx); @@ -6660,7 +6660,7 @@ void RM_ScanCursorDestroy(RedisModuleScanCursor *cursor) { * Moreover playing with the Redis keyspace while iterating may have the * effect of returning more duplicates. A safe pattern is to store the keys * names you want to modify elsewhere, and perform the actions on the keys - * later when the iteration is complete. Howerver this can cost a lot of + * later when the iteration is complete. However this can cost a lot of * memory, so it may make sense to just operate on the current key when * possible during the iteration, given that this is safe. */ int RM_Scan(RedisModuleCtx *ctx, RedisModuleScanCursor *cursor, RedisModuleScanCB fn, void *privdata) { @@ -6895,7 +6895,7 @@ int TerminateModuleForkChild(int child_pid, int wait) { } /* Can be used to kill the forked child process from the parent process. - * child_pid whould be the return value of RedisModule_Fork. */ + * child_pid would be the return value of RedisModule_Fork. */ int RM_KillForkChild(int child_pid) { /* Kill module child, wait for child exit. */ if (TerminateModuleForkChild(child_pid,1) == C_OK) @@ -7033,7 +7033,7 @@ void ModuleForkDoneHandler(int exitcode, int bysignal) { * REDISMODULE_SUBEVENT_LOADING_FAILED * * Note that AOF loading may start with an RDB data in case of - * rdb-preamble, in which case you'll only recieve an AOF_START event. + * rdb-preamble, in which case you'll only receive an AOF_START event. * * * RedisModuleEvent_ClientChange @@ -7055,7 +7055,7 @@ void ModuleForkDoneHandler(int exitcode, int bysignal) { * This event is called when the instance (that can be both a * master or a replica) get a new online replica, or lose a * replica since it gets disconnected. - * The following sub events are availble: + * The following sub events are available: * * REDISMODULE_SUBEVENT_REPLICA_CHANGE_ONLINE * REDISMODULE_SUBEVENT_REPLICA_CHANGE_OFFLINE @@ -7093,7 +7093,7 @@ void ModuleForkDoneHandler(int exitcode, int bysignal) { * RedisModuleEvent_ModuleChange * * This event is called when a new module is loaded or one is unloaded. - * The following sub events are availble: + * The following sub events are available: * * REDISMODULE_SUBEVENT_MODULE_LOADED * REDISMODULE_SUBEVENT_MODULE_UNLOADED @@ -7120,7 +7120,7 @@ void ModuleForkDoneHandler(int exitcode, int bysignal) { * int32_t progress; // Approximate progress between 0 and 1024, * or -1 if unknown. * - * The function returns REDISMODULE_OK if the module was successfully subscrived + * The function returns REDISMODULE_OK if the module was successfully subscribed * for the specified event. If the API is called from a wrong context then * REDISMODULE_ERR is returned. */ int RM_SubscribeToServerEvent(RedisModuleCtx *ctx, RedisModuleEvent event, RedisModuleEventCallback callback) { @@ -7687,7 +7687,7 @@ size_t moduleCount(void) { return dictSize(modules); } -/* Set the key last access time for LRU based eviction. not relevent if the +/* Set the key last access time for LRU based eviction. not relevant if the * servers's maxmemory policy is LFU based. Value is idle time in milliseconds. * returns REDISMODULE_OK if the LRU was updated, REDISMODULE_ERR otherwise. */ int RM_SetLRU(RedisModuleKey *key, mstime_t lru_idle) { diff --git a/src/siphash.c b/src/siphash.c index 3577411325..65f19ca8de 100644 --- a/src/siphash.c +++ b/src/siphash.c @@ -46,7 +46,7 @@ #include /* Fast tolower() alike function that does not care about locale - * but just returns a-z insetad of A-Z. */ + * but just returns a-z instead of A-Z. */ int siptlw(int c) { if (c >= 'A' && c <= 'Z') { return c+('a'-'A'); diff --git a/src/slowlog.c b/src/slowlog.c index 1d715e39b7..408456b14e 100644 --- a/src/slowlog.c +++ b/src/slowlog.c @@ -75,7 +75,7 @@ slowlogEntry *slowlogCreateEntry(client *c, robj **argv, int argc, long long dur } else if (argv[j]->refcount == OBJ_SHARED_REFCOUNT) { se->argv[j] = argv[j]; } else { - /* Here we need to dupliacate the string objects composing the + /* Here we need to duplicate the string objects composing the * argument vector of the command, because those may otherwise * end shared with string objects stored into keys. Having * shared objects between any part of Redis, and the data diff --git a/src/sort.c b/src/sort.c index f269a77314..aeef53e6a8 100644 --- a/src/sort.c +++ b/src/sort.c @@ -115,7 +115,7 @@ robj *lookupKeyByPattern(redisDb *db, robj *pattern, robj *subst, int writeflag) if (fieldobj) { if (o->type != OBJ_HASH) goto noobj; - /* Retrieve value from hash by the field name. The returend object + /* Retrieve value from hash by the field name. The returned object * is a new object with refcount already incremented. */ o = hashTypeGetValueObject(o, fieldobj->ptr); } else { diff --git a/src/t_stream.c b/src/t_stream.c index 1ab85a3b1d..67415e65f8 100644 --- a/src/t_stream.c +++ b/src/t_stream.c @@ -1890,7 +1890,7 @@ NULL } } -/* XSETID +/* XSETID * * Set the internal "last ID" of a stream. */ void xsetidCommand(client *c) { diff --git a/src/t_string.c b/src/t_string.c index 93910e5a9e..6c54a6fe99 100644 --- a/src/t_string.c +++ b/src/t_string.c @@ -315,7 +315,7 @@ void msetGenericCommand(client *c, int nx) { } /* Handle the NX flag. The MSETNX semantic is to return zero and don't - * set anything if at least one key alerady exists. */ + * set anything if at least one key already exists. */ if (nx) { for (j = 1; j < c->argc; j += 2) { if (lookupKeyWrite(c->db,c->argv[j]) != NULL) { diff --git a/src/ziplist.c b/src/ziplist.c index 13881c1175..65e7b0b2e0 100644 --- a/src/ziplist.c +++ b/src/ziplist.c @@ -325,7 +325,7 @@ unsigned int zipIntSize(unsigned char encoding) { * for single-byte small immediate integers. * * 'rawlen' is only used for ZIP_STR_* encodings and is the length of the - * srting that this entry represents. + * string that this entry represents. * * The function returns the number of bytes used by the encoding/length * header stored in 'p'. */ diff --git a/tests/instances.tcl b/tests/instances.tcl index a43a4cc873..283352b30a 100644 --- a/tests/instances.tcl +++ b/tests/instances.tcl @@ -273,7 +273,7 @@ proc pause_on_error {} { puts "S cmd ... arg Call command in Sentinel ." puts "R cmd ... arg Call command in Redis ." puts "SI Show Sentinel INFO ." - puts "RI Show Sentinel INFO ." + puts "RI Show Redis INFO ." puts "continue Resume test." } else { set errcode [catch {eval $line} retval]