summaryrefslogtreecommitdiffstats
path: root/hash.h
AgeCommit message (Collapse)Author
2019-01-04Clean up code indentation.Kevin McCarthy
These are mostly automated changes corresponding to the emacs settings: (c-set-style "linux") (setq c-basic-offset 2) (c-set-offset 'case-label '+) Most of the code follows the convention: (add-to-list 'c-cleanup-list 'space-before-funcall) but this is not enforced by this indentation cleanup. Also, I personally dislike tabs, so I have: (setq-default indent-tabs-mode nil) in my own configuration. However I have no desire to change every line just for that effect. So this cleanup does nothing about the mix issue. Some of the secondary files (e.g. regex.c) have been skipped. I've also skipped crypt-gpgme.c, because I need to think about that file. Werner Koch and the GnuPG team contributed most it, and it follows the Gnu indentation settings. It should probably be made uniform with Mutt, but I don't want to discourage future GnuPG contribution to the file. I manually reverted a few unsightly cleanups, and added a few tweeks when I saw things that could be improved.
2018-12-31Remove trailing whitespace.Kevin McCarthy
The result of find . -name "*.[ch]" -exec emacs -batch {} \ --eval="(progn (delete-trailing-whitespace) (and (buffer-modified-p) (save-buffer)))" \;
2017-02-10Change "allow_dups" into a flag at hash creation.Kevin McCarthy
Instead of having an "allow_dups" parameter for hash_insert(), add a flag, MUTT_HASH_ALLOW_DUPS, to hash_create(). Currently ReverseAlias, subj_hash, and thread_hash allow duplicate keys. Change those hashes to pass the flag at creation, and remove the last parameter from all callers of hash_insert().
2017-01-28Add hash_find_elem to get the hash element.Kevin McCarthy
This will be used in the following patch for directly manipulating the label counter.
2017-01-28Add reentrant hash_walk() function for iterating down a hash table.David Champion
2017-01-17Add casecmp and strdup_key flags to hash_create()Kevin McCarthy
Aliases and (in the future), X-Label hashes will require a hash that strdups the key. Convert the casecmp parameter of hash_create() to a flags parameter, and add a flag to strdup the keys.
2017-01-06Convert HASH to be indexable by unsigned int. (see #3905)Kevin McCarthy
Convert the HASH to be usable for either string or unsigned int keys, so that a uid hash can be added for imap. To keep hash-usage code disruption to a minimum, this introduces new create/insert/find/delete functions for the int hash, but keeps the old function names for string keys. This implementation makes the key a union. It may have been a better idea to introduce a whole new structure, but this way allows minimum changes to and maximum reuse of the existing hash code.
2009-03-09Restore $reverse_alias feature by using case-insensitive hash keysRocco Rutte
The fix is implemented as callbacks in the hash table so we can avoid working with copies of the mailbox keys but work on the originals instead and don't pollute the code with lower-case conversions all over the place. While I'm at it, turn int hashes into unsigned values since the hash function returns unsigned values now, too. Closes #3185.
2009-01-03Make hash_string work in unsigned domainBrendan Cully
2005-09-17Gah, forgot the zip code when updating the FSF address...Brendan Cully
2005-09-17Update FSF address (via sed, I hope nothing got mangled). Closes: #2071.Brendan Cully
2002-12-11Fix Mike's and my e-mail addresses in copyright lines.Thomas Roessler
2000-03-03The FSF apparently has moved.Thomas Roessler
2000-01-06Update copyright notices for unstable.Thomas Roessler
1999-01-07Get rid of RCS ids in source files. They are getting in our wayThomas Roessler
when merging changes.
1998-10-13Add RCS $Id$ strings to (hopefully) all source files.Thomas Roessler
1998-09-13This patch adds on-demand loading of character set tables,Thomas Roessler
changes the default location of $SHAREDIR, and fixes some compilation problems occuring on machines without PGP installed.
1998-06-08Initial revisionThomas Roessler