summaryrefslogtreecommitdiffstats
path: root/libidu/hash.c
Commit message (Collapse)AuthorAgeFilesLines
* rename hash.? to idu-hash.? to avoid conflict with gnulib's hash.hJim Meyering2009-08-151-311/+0
| | | | | | | | | | | | | Now that gnulib's exclude module uses gnulib's hash module, which includes a hash.h file, idutils' use of a hash.h file conflicted. Rename the one here in idutils: * libidu/idu-hash.c: Rename from hash.c. * libidu/idu-hash.h: Rename from hash.h. * libidu/idfile.h: Reflect renaming. * libidu/idread.c: Likewise. * libidu/idwrite.c: Likewise. * src/mkid.c: Likewise. * libidu/Makefile.am: Likewise.
* maint: add const attribute to a few declarationsJim Meyering2009-06-071-3/+3
| | | | | | * libidu/hash.c (hash_print_stats, hash_dump): Add const. * libidu/hash.h: Likewise. * src/mkid.c (scan_files): Likewise.
* Don't cast x*alloc return value.Jim Meyering2008-01-141-3/+3
| | | | | | | * libidu/hash.c (hash_rehash): Remove cast. (hash_init): Likewise. Signed-off-by: Jim Meyering <meyering@redhat.com>
* License upgrade to "GPL-3 or later"Pedro J. Ruiz Lopez2007-08-171-4/+3
|
* * started to address portability problems in the id-utils-4.0 releaseClaudio Fontana2005-12-271-2/+3
|
* *** empty log message ***Claudio Fontana2005-11-011-7/+7
|
* Update copyright notices for 1999Greg McGary1999-04-041-1/+1
|
* * libidu/hash.c (hash_insert): hash_insert_at no longerGreg McGary1999-03-281-3/+9
| | | | | | | | | returns old contents, but rather the new slot address. (hash_insert_at): Return slot address of inserted item. * libidu/walker.c (get_member_file): return member. (get_link_from_dirent, get_link_from_string): Conform to new hash_insert_at API, where return value is slot address of newly inserted item.
* * hash.h (struct hash_table) [ht_empty_slots]: Add struct member.Greg McGary1999-01-261-12/+23
| | | | | | | | | | * hash.c (hash_init): Initialize ht_empty_slots. Don't halve ht_size. (hash_find_slot) Return deleted slot, if available. (hash_insert_at): Decrement ht_empty_slots if one is consumed. Rehash if emtpy slots become too scarce. (hash_free_items, hash_deleted_item, hash_free): Re-initialize ht_empty_slots. (hash_rehash): Don't double table size if rehashing only because table is clogged with deleted slots.
* Initial revisionGreg McGary1997-04-181-0/+294