aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/dbm.c
Commit message (Collapse)AuthorAgeFilesLines
* delete trailing whitespace and space-tab sequences; no code change;Ingo Schwarze2019-07-011-3/+3
| | | | | patch from Michal Nowak <mnowak at startmail dot com> who found these with git pbchk in the illumos tree
* Correctly construct empty lists in dbm_page_get().Ingo Schwarze2018-11-191-4/+4
| | | | | | | | | | Original commit message by the author of this bugfix patch, bluhm@: lstmatch() expects a list of strings separated by \0 and terminated with \0\0. In the NULL case dbm_page_get() returned only simple strings so correct processing was depending on data layout. Use an additional \0 to terminate the single string lists. Found by mandoc regress since llvm linker on amd64 arranges strings differently.
* The termination condition of the iteration logic in page_bymacro()Ingo Schwarze2016-10-181-19/+23
| | | | | | | was overzealous. Consequently, macro=substr and macro~regexp searches only returned all pages containing the first matching macro value, rather than all pages containing any of the matching macro values. Bug reported by tb@ - thanks!
* When the database is corrupt in the sense of containing invalidIngo Schwarze2016-08-301-2/+16
| | | | | | | | | pointers in the pages table, do not access NULL pointers, but gracefully handle the errors. Similar patches will be needed for the macro tables, too. <attila at stalphonsos dot com> audited the code and pointed out to me that dbm_get() can return NULL for corrupted databases, but that isn't handled properly at various places.
* The concept of endianness seems to be somewhat newfangled, so theIngo Schwarze2016-08-051-1/+7
| | | | | | respective conversion functions are not yet properly standardized. Rumour has it that POSIX is working on it, though. For now, sprinkle some configuration glue.
* Linux compatibility: Work around the lack of EFTYPE and protect <err.h>.Ingo Schwarze2016-07-201-1/+5
|
* Remove the dependency on SQLite without loss of functionality.Ingo Schwarze2016-07-191-0/+452
Stop supporting systems that don't have mmap(3). Drop the obsolete names_check() now that we deleted MLINKS.