Fixed some spelling errors in the comments

This commit is contained in:
Erik Dubbelboer 2012-04-07 14:40:29 +02:00
parent 69e7958918
commit 65fd32ab0a
4 changed files with 16 additions and 16 deletions

View File

@ -116,8 +116,8 @@ unsigned int dictGenCaseHashFunction(const unsigned char *buf, int len) {
/* ----------------------------- API implementation ------------------------- */ /* ----------------------------- API implementation ------------------------- */
/* Reset an hashtable already initialized with ht_init(). /* Reset a hash table already initialized with ht_init().
* NOTE: This function should only called by ht_destroy(). */ * NOTE: This function should only be called by ht_destroy(). */
static void _dictReset(dictht *ht) static void _dictReset(dictht *ht)
{ {
ht->table = NULL; ht->table = NULL;
@ -280,7 +280,7 @@ int dictAdd(dict *d, void *key, void *val)
* a value returns the dictEntry structure to the user, that will make * a value returns the dictEntry structure to the user, that will make
* sure to fill the value field as he wishes. * sure to fill the value field as he wishes.
* *
* This function is also directly expoed to user API to be called * This function is also directly exposed to user API to be called
* mainly in order to store non-pointers inside the hash value, example: * mainly in order to store non-pointers inside the hash value, example:
* *
* entry = dictAddRaw(dict,mykey); * entry = dictAddRaw(dict,mykey);

View File

@ -52,15 +52,15 @@
* <len> lengths are encoded in a single value or in a 5 bytes value. * <len> lengths are encoded in a single value or in a 5 bytes value.
* If the first byte value (as an unsigned 8 bit value) is between 0 and * If the first byte value (as an unsigned 8 bit value) is between 0 and
* 252, it's a single-byte length. If it is 253 then a four bytes unsigned * 252, it's a single-byte length. If it is 253 then a four bytes unsigned
* integer follows (in the host byte ordering). A value fo 255 is used to * integer follows (in the host byte ordering). A value of 255 is used to
* signal the end of the hash. The special value 254 is used to mark * signal the end of the hash. The special value 254 is used to mark
* empty space that can be used to add new key/value pairs. * empty space that can be used to add new key/value pairs.
* *
* <free> is the number of free unused bytes * <free> is the number of free unused bytes after the string, resulting
* after the string, resulting from modification of values associated to a * from modification of values associated to a key. For instance if "foo"
* key (for instance if "foo" is set to "bar', and later "foo" will be se to * is set to "bar", and later "foo" will be set to "hi", it will have a
* "hi", I'll have a free byte to use if the value will enlarge again later, * free byte to use if the value will enlarge again later, or even in
* or even in order to add a key/value pair if it fits. * order to add a key/value pair if it fits.
* *
* <free> is always an unsigned 8 bit number, because if after an * <free> is always an unsigned 8 bit number, because if after an
* update operation there are more than a few free bytes, the zipmap will be * update operation there are more than a few free bytes, the zipmap will be