Skip to content

Commit

Permalink
Fixed many typos.
Browse files Browse the repository at this point in the history
  • Loading branch information
guiquanz authored and antirez committed Jan 19, 2013
1 parent 61dfc2e commit 9d09ce3
Show file tree
Hide file tree
Showing 42 changed files with 154 additions and 154 deletions.
4 changes: 2 additions & 2 deletions 00-RELEASENOTES
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Also the following redis.conf and CONFIG GET / SET parameters changed name:

* hash-max-zipmap-entries, now replaced by hash-max-ziplist-entries
* hash-max-zipmap-value, now replaced by hash-max-ziplist-value
* glueoutputbuf was no completely removed as it does not make sense
* glueoutputbuf was now completely removed as it does not make sense

---------
CHANGELOG
Expand All @@ -46,7 +46,7 @@ UPGRADE URGENCY: We suggest new users to start with 2.6.0, and old users to
in slaves.
* Milliseconds resolution expires, also added new commands with milliseconds
precision (PEXPIRE, PTTL, ...).
* Clinets max output buffer soft and hard limits. You can specifiy different
* Clients max output buffer soft and hard limits. You can specifiy different
limits for different classes of clients (normal,pubsub,slave).
* AOF is now able to rewrite aggregate data types using variadic commands,
often producing an AOF that is faster to save, load, and is smaller in size.
Expand Down
2 changes: 1 addition & 1 deletion redis.conf
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ slave-priority 100

# Set the max number of connected clients at the same time. By default
# this limit is set to 10000 clients, however if the Redis server is not
# able ot configure the process file limit to allow for the specified limit
# able to configure the process file limit to allow for the specified limit
# the max number of allowed clients is set to the current file limit
# minus 32 (as Redis reserves a few file descriptors for internal uses).
#
Expand Down
2 changes: 1 addition & 1 deletion sentinel.conf
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ sentinel parallel-syncs mymaster 1
# Default is 15 minutes.
sentinel failover-timeout mymaster 900000

# SCRIPTS EXECTION
# SCRIPTS EXECUTION
#
# sentinel notification-script and sentinel reconfig-script are used in order
# to configure scripts that are called to notify the system administrator
Expand Down
6 changes: 3 additions & 3 deletions src/adlist.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ list *listAddNodeHead(list *list, void *value)
return list;
}

/* Add a new node to the list, to tail, contaning the specified 'value'
/* Add a new node to the list, to tail, containing the specified 'value'
* pointer as value.
*
* On error, NULL is returned and no operation is performed (i.e. the
Expand Down Expand Up @@ -308,7 +308,7 @@ listNode *listSearchKey(list *list, void *key)
/* Return the element at the specified zero-based index
* where 0 is the head, 1 is the element next to head
* and so on. Negative integers are used in order to count
* from the tail, -1 is the last element, -2 the penultimante
* from the tail, -1 is the last element, -2 the penultimate
* and so on. If the index is out of range NULL is returned. */
listNode *listIndex(list *list, long index) {
listNode *n;
Expand All @@ -330,7 +330,7 @@ void listRotate(list *list) {

if (listLength(list) <= 1) return;

/* Detatch current tail */
/* Detach current tail */
list->tail = tail->prev;
list->tail->next = NULL;
/* Move it as head */
Expand Down
6 changes: 3 additions & 3 deletions src/ae.c
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ static int processTimeEvents(aeEventLoop *eventLoop) {
/* Process every pending time event, then every pending file event
* (that may be registered by time event callbacks just processed).
* Without special flags the function sleeps until some file event
* fires, or when the next time event occurrs (if any).
* fires, or when the next time event occurs (if any).
*
* If flags is 0, the function does nothing and returns.
* if flags has AE_ALL_EVENTS set, all the kind of events are processed.
Expand Down Expand Up @@ -356,7 +356,7 @@ int aeProcessEvents(aeEventLoop *eventLoop, int flags)
if (tvp->tv_usec < 0) tvp->tv_usec = 0;
} else {
/* If we have to check for events but need to return
* ASAP because of AE_DONT_WAIT we need to se the timeout
* ASAP because of AE_DONT_WAIT we need to set the timeout
* to zero */
if (flags & AE_DONT_WAIT) {
tv.tv_sec = tv.tv_usec = 0;
Expand Down Expand Up @@ -395,7 +395,7 @@ int aeProcessEvents(aeEventLoop *eventLoop, int flags)
return processed; /* return the number of processed file/time events */
}

/* Wait for millseconds until the given file descriptor becomes
/* Wait for milliseconds until the given file descriptor becomes
* writable/readable/exception */
int aeWait(int fd, int mask, long long milliseconds) {
struct pollfd pfd;
Expand Down
12 changes: 6 additions & 6 deletions src/ae_evport.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,15 @@ static int evport_debug = 0;
* aeApiPoll, the corresponding file descriptors become dissociated from the
* port. This is necessary because poll events are level-triggered, so if the
* fd didn't become dissociated, it would immediately fire another event since
* the underlying state hasn't changed yet. We must reassociate the file
* the underlying state hasn't changed yet. We must re-associate the file
* descriptor, but only after we know that our caller has actually read from it.
* The ae API does not tell us exactly when that happens, but we do know that
* it must happen by the time aeApiPoll is called again. Our solution is to
* keep track of the last fds returned by aeApiPoll and reassociate them next
* keep track of the last fds returned by aeApiPoll and re-associate them next
* time aeApiPoll is invoked.
*
* To summarize, in this module, each fd association is EITHER (a) represented
* only via the in-kernel assocation OR (b) represented by pending_fds and
* only via the in-kernel association OR (b) represented by pending_fds and
* pending_masks. (b) is only true for the last fds we returned from aeApiPoll,
* and only until we enter aeApiPoll again (at which point we restore the
* in-kernel association).
Expand Down Expand Up @@ -164,7 +164,7 @@ static int aeApiAddEvent(aeEventLoop *eventLoop, int fd, int mask) {
* This fd was recently returned from aeApiPoll. It should be safe to
* assume that the consumer has processed that poll event, but we play
* it safer by simply updating pending_mask. The fd will be
* reassociated as usual when aeApiPoll is called again.
* re-associated as usual when aeApiPoll is called again.
*/
if (evport_debug)
fprintf(stderr, "aeApiAddEvent: adding to pending fd %d\n", fd);
Expand Down Expand Up @@ -228,7 +228,7 @@ static void aeApiDelEvent(aeEventLoop *eventLoop, int fd, int mask) {
* ENOMEM is a potentially transient condition, but the kernel won't
* generally return it unless things are really bad. EAGAIN indicates
* we've reached an resource limit, for which it doesn't make sense to
* retry (counterintuitively). All other errors indicate a bug. In any
* retry (counter-intuitively). All other errors indicate a bug. In any
* of these cases, the best we can do is to abort.
*/
abort(); /* will not return */
Expand All @@ -243,7 +243,7 @@ static int aeApiPoll(aeEventLoop *eventLoop, struct timeval *tvp) {
port_event_t event[MAX_EVENT_BATCHSZ];

/*
* If we've returned fd events before, we must reassociate them with the
* If we've returned fd events before, we must re-associate them with the
* port now, before calling port_get(). See the block comment at the top of
* this file for an explanation of why.
*/
Expand Down
4 changes: 2 additions & 2 deletions src/anet.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ int anetNonBlock(char *err, int fd)
{
int flags;

/* Set the socket nonblocking.
/* Set the socket non-blocking.
* Note that fcntl(2) for F_GETFL and F_SETFL can't be
* interrupted by a signal. */
if ((flags = fcntl(fd, F_GETFL)) == -1) {
Expand Down Expand Up @@ -132,7 +132,7 @@ static int anetCreateSocket(char *err, int domain) {
return ANET_ERR;
}

/* Make sure connection-intensive things like the redis benckmark
/* Make sure connection-intensive things like the redis benchmark
* will be able to close/open sockets a zillion of times */
if (setsockopt(s, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) == -1) {
anetSetError(err, "setsockopt SO_REUSEADDR: %s", strerror(errno));
Expand Down
2 changes: 1 addition & 1 deletion src/aof.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ void feedAppendOnlyFile(struct redisCommand *cmd, int dictid, robj **argv, int a
sds buf = sdsempty();
robj *tmpargv[3];

/* The DB this command was targetting is not the same as the last command
/* The DB this command was targeting is not the same as the last command
* we appendend. To issue a SELECT command is needed. */
if (dictid != server.aof_selected_db) {
char seldb[64];
Expand Down
2 changes: 1 addition & 1 deletion src/bio.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ static list *bio_jobs[REDIS_BIO_NUM_OPS];
static unsigned long long bio_pending[REDIS_BIO_NUM_OPS];

/* This structure represents a background Job. It is only used locally to this
* file as the API deos not expose the internals at all. */
* file as the API does not expose the internals at all. */
struct bio_job {
time_t time; /* Time at which the job was created. */
/* Job specific arguments pointers. If we need to pass more than three
Expand Down
4 changes: 2 additions & 2 deletions src/bitops.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
* Helpers and low level bit functions.
* -------------------------------------------------------------------------- */

/* This helper function used by GETBIT / SETBIT parses the bit offset arguemnt
/* This helper function used by GETBIT / SETBIT parses the bit offset argument
* making sure an error is returned if it is negative or if it overflows
* Redis 512 MB limit for the string value. */
static int getBitOffsetFromArgument(redisClient *c, robj *o, size_t *offset) {
Expand Down Expand Up @@ -189,7 +189,7 @@ void bitopCommand(redisClient *c) {
char *opname = c->argv[1]->ptr;
robj *o, *targetkey = c->argv[2];
long op, j, numkeys;
robj **objects; /* Array of soruce objects. */
robj **objects; /* Array of source objects. */
unsigned char **src; /* Array of source strings pointers. */
long *len, maxlen = 0; /* Array of length of src strings, and max len. */
long minlen = 0; /* Min len among the input keys. */
Expand Down
12 changes: 6 additions & 6 deletions src/cluster.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ int clusterLoadConfig(char *filename) {
return REDIS_OK;

fmterr:
redisLog(REDIS_WARNING,"Unrecovarable error: corrupted cluster config file.");
redisLog(REDIS_WARNING,"Unrecoverable error: corrupted cluster config file.");
fclose(fp);
exit(1);
}
Expand Down Expand Up @@ -985,7 +985,7 @@ void clusterCron(void) {
time_t min_ping_sent = 0;
clusterNode *min_ping_node = NULL;

/* Check if we have disconnected nodes and reestablish the connection. */
/* Check if we have disconnected nodes and re-establish the connection. */
di = dictGetIterator(server.cluster.nodes);
while((de = dictNext(di)) != NULL) {
clusterNode *node = dictGetVal(de);
Expand Down Expand Up @@ -1069,7 +1069,7 @@ void clusterCron(void) {
clusterUpdateState();
}
} else {
/* Timeout reached. Set the noad se possibly failing if it is
/* Timeout reached. Set the node as possibly failing if it is
* not already in this state. */
if (!(node->flags & (REDIS_NODE_PFAIL|REDIS_NODE_FAIL))) {
redisLog(REDIS_DEBUG,"*** NODE %.40s possibly failing",
Expand Down Expand Up @@ -1803,7 +1803,7 @@ void migrateCommand(redisClient *c) {
redisAssertWithInfo(c,NULL,rioWriteBulkString(&cmd,c->argv[3]->ptr,sdslen(c->argv[3]->ptr)));
redisAssertWithInfo(c,NULL,rioWriteBulkLongLong(&cmd,ttl));

/* Emit the payload argument, that is the serailized object using
/* Emit the payload argument, that is the serialized object using
* the DUMP format. */
createDumpPayload(&payload,o);
redisAssertWithInfo(c,NULL,rioWriteBulkString(&cmd,payload.io.buffer.ptr,
Expand All @@ -1815,7 +1815,7 @@ void migrateCommand(redisClient *c) {
if (replace)
redisAssertWithInfo(c,NULL,rioWriteBulkString(&cmd,"REPLACE",7));

/* Tranfer the query to the other node in 64K chunks. */
/* Transfer the query to the other node in 64K chunks. */
errno = 0;
{
sds buf = cmd.io.buffer.ptr;
Expand Down Expand Up @@ -1882,7 +1882,7 @@ void migrateCommand(redisClient *c) {
}

/* The ASKING command is required after a -ASK redirection.
* The client should issue ASKING before to actualy send the command to
* The client should issue ASKING before to actually send the command to
* the target instance. See the Redis Cluster specification for more
* information. */
void askingCommand(redisClient *c) {
Expand Down
6 changes: 3 additions & 3 deletions src/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ void loadServerConfigFromString(char *config) {
goto loaderr;
}

/* If the target command name is the emtpy string we just
/* If the target command name is the empty string we just
* remove it from the command table. */
retval = dictDelete(server.commands, argv[1]);
redisAssert(retval == DICT_OK);
Expand Down Expand Up @@ -378,7 +378,7 @@ void loadServerConfigFromString(char *config) {
soft = memtoll(argv[3],NULL);
soft_seconds = atoi(argv[4]);
if (soft_seconds < 0) {
err = "Negative number of seconds in soft limt is invalid";
err = "Negative number of seconds in soft limit is invalid";
goto loaderr;
}
server.client_obuf_limits[class].hard_limit_bytes = hard;
Expand Down Expand Up @@ -423,7 +423,7 @@ void loadServerConfigFromString(char *config) {
* in the 'options' string to the config file before loading.
*
* Both filename and options can be NULL, in such a case are considered
* emtpy. This way loadServerConfig can be used to just load a file or
* empty. This way loadServerConfig can be used to just load a file or
* just load a string. */
void loadServerConfig(char *filename, char *options) {
sds config = sdsempty();
Expand Down
2 changes: 1 addition & 1 deletion src/crc16.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

/* CRC16 implementation acording to CCITT standards.
/* CRC16 implementation according to CCITT standards.
*
* Note by @antirez: this is actually the XMODEM CRC 16 algorithm, using the
* following parameters:
Expand Down
6 changes: 3 additions & 3 deletions src/db.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ robj *lookupKey(redisDb *db, robj *key) {
if (de) {
robj *val = dictGetVal(de);

/* Update the access time for the aging algorithm.
/* Update the access time for the ageing algorithm.
* Don't do it if we have a saving child, as this will trigger
* a copy on write madness. */
if (server.rdb_child_pid == -1 && server.aof_child_pid == -1)
Expand Down Expand Up @@ -85,7 +85,7 @@ robj *lookupKeyWriteOrReply(redisClient *c, robj *key, robj *reply) {
}

/* Add the key to the DB. It's up to the caller to increment the reference
* counte of the value if needed.
* counter of the value if needed.
*
* The program is aborted if the key already exists. */
void dbAdd(redisDb *db, robj *key, robj *val) {
Expand Down Expand Up @@ -549,7 +549,7 @@ int expireIfNeeded(redisDb *db, robj *key) {
* for *AT variants of the command, or the current time for relative expires).
*
* unit is either UNIT_SECONDS or UNIT_MILLISECONDS, and is only used for
* the argv[2] parameter. The basetime is always specified in milliesconds. */
* the argv[2] parameter. The basetime is always specified in milliseconds. */
void expireGenericCommand(redisClient *c, long long basetime, int unit) {
dictEntry *de;
robj *key = c->argv[1], *param = c->argv[2];
Expand Down
4 changes: 2 additions & 2 deletions src/debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
/* ================================= Debugging ============================== */

/* Compute the sha1 of string at 's' with 'len' bytes long.
* The SHA1 is then xored againt the string pointed by digest.
* The SHA1 is then xored against the string pointed by digest.
* Since xor is commutative, this operation is used in order to
* "add" digests relative to unordered elements.
*
Expand All @@ -69,7 +69,7 @@ void xorObjectDigest(unsigned char *digest, robj *o) {
}

/* This function instead of just computing the SHA1 and xoring it
* against diget, also perform the digest of "digest" itself and
* against digest, also perform the digest of "digest" itself and
* replace the old value with the new one.
*
* So the final digest will be:
Expand Down
2 changes: 1 addition & 1 deletion src/dict.c
Original file line number Diff line number Diff line change
Expand Up @@ -610,7 +610,7 @@ static int _dictExpandIfNeeded(dict *d)
/* Incremental rehashing already in progress. Return. */
if (dictIsRehashing(d)) return DICT_OK;

/* If the hash table is empty expand it to the intial size. */
/* If the hash table is empty expand it to the initial size. */
if (d->ht[0].size == 0) return dictExpand(d, DICT_HT_INITIAL_SIZE);

/* If we reached the 1:1 ratio, and we are allowed to resize the hash
Expand Down
8 changes: 4 additions & 4 deletions src/lzfP.h
Original file line number Diff line number Diff line change
Expand Up @@ -93,15 +93,15 @@

/*
* Avoid assigning values to errno variable? for some embedding purposes
* (linux kernel for example), this is neccessary. NOTE: this breaks
* (linux kernel for example), this is necessary. NOTE: this breaks
* the documentation in lzf.h.
*/
#ifndef AVOID_ERRNO
# define AVOID_ERRNO 0
#endif

/*
* Wether to pass the LZF_STATE variable as argument, or allocate it
* Whether to pass the LZF_STATE variable as argument, or allocate it
* on the stack. For small-stack environments, define this to 1.
* NOTE: this breaks the prototype in lzf.h.
*/
Expand All @@ -110,11 +110,11 @@
#endif

/*
* Wether to add extra checks for input validity in lzf_decompress
* Whether to add extra checks for input validity in lzf_decompress
* and return EINVAL if the input stream has been corrupted. This
* only shields against overflowing the input buffer and will not
* detect most corrupted streams.
* This check is not normally noticable on modern hardware
* This check is not normally noticeable on modern hardware
* (<1% slowdown), but might slow down older cpus considerably.
*/
#ifndef CHECK_INPUT
Expand Down
2 changes: 1 addition & 1 deletion src/mkreleasehdr.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ GIT_DIRTY=`git diff 2> /dev/null | wc -l`
BUILD_ID=`uname -n`"-"`date +%s`
test -f release.h || touch release.h
(cat release.h | grep SHA1 | grep $GIT_SHA1) && \
(cat release.h | grep DIRTY | grep $GIT_DIRTY) && exit 0 # Already uptodate
(cat release.h | grep DIRTY | grep $GIT_DIRTY) && exit 0 # Already up-to-date
echo "#define REDIS_GIT_SHA1 \"$GIT_SHA1\"" > release.h
echo "#define REDIS_GIT_DIRTY \"$GIT_DIRTY\"" >> release.h
echo "#define REDIS_BUILD_ID \"$BUILD_ID\"" >> release.h
Expand Down
4 changes: 2 additions & 2 deletions src/multi.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ void discardCommand(redisClient *c) {
}

/* Send a MULTI command to all the slaves and AOF file. Check the execCommand
* implememntation for more information. */
* implementation for more information. */
void execCommandReplicateMulti(redisClient *c) {
robj *multistring = createStringObject("MULTI",5);

Expand Down Expand Up @@ -223,7 +223,7 @@ void watchForKey(redisClient *c, robj *key) {
incrRefCount(key);
}
listAddNodeTail(clients,c);
/* Add the new key to the lits of keys watched by this client */
/* Add the new key to the list of keys watched by this client */
wk = zmalloc(sizeof(*wk));
wk->key = key;
wk->db = c->db;
Expand Down
Loading

0 comments on commit 9d09ce3

Please sign in to comment.