Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
John McEleney
/
mailutils
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
fc26d92d
...
fc26d92d2fec6139f1b96dc3fec750e7b507e812
authored
2006-04-19 13:27:53 +0000
by
Sergey Poznyakoff
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Add support for Berkeley DB >= 3
1 parent
30f5f2ac
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
5 deletions
lib/mu_dbm.c
lib/mu_dbm.h
pop3d/popauth.c
lib/mu_dbm.c
View file @
fc26d92
/* GNU Mailutils -- a suite of utilities for electronic mail
Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Copyright (C) 1999, 2000, 2001, 2002
, 2006
Free Software Foundation, Inc.
GNU Mailutils is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
...
...
@@ -197,7 +197,7 @@ mu_dbm_nextkey (DBM_FILE db, DBM_DATUM key)
return
gdbm_nextkey
(
db
,
key
);
}
#elif defined(WITH_BDB
2
)
#elif defined(WITH_BDB)
#define DB_SUFFIX ".db"
...
...
@@ -241,7 +241,15 @@ mu_dbm_open (char *name, DBM_FILE *dbm, int flags, int mode)
return
-
1
;
}
#if WITH_BDB == 2
rc
=
db_open
(
pfname
,
DB_HASH
,
f
,
mode
,
NULL
,
NULL
,
&
db
);
#else
rc
=
db_create
(
&
db
,
NULL
,
0
);
if
(
rc
!=
0
||
db
==
NULL
)
return
rc
;
rc
=
db
->
open
(
db
,
pfname
,
NULL
,
DB_HASH
,
f
,
mode
);
#endif
free
(
pfname
);
if
(
rc
)
return
-
1
;
...
...
lib/mu_dbm.h
View file @
fc26d92
...
...
@@ -27,7 +27,7 @@ typedef datum DBM_DATUM;
#define MU_DATUM_SIZE(d) d.dsize
#define MU_DATUM_PTR(d) d.dptr
#elif defined(WITH_BDB
2
)
#elif defined(WITH_BDB)
#include <db.h>
#define USE_DBM
...
...
pop3d/popauth.c
View file @
fc26d92
...
...
@@ -580,8 +580,8 @@ popauth_version (FILE *stream, struct argp_state *state)
{
#if defined(WITH_GDBM)
# define FORMAT "GDBM"
#elif defined(WITH_BDB
2
)
# define FORMAT "Berkeley DB"
#elif defined(WITH_BDB)
# define FORMAT "Berkeley DB"
#elif defined(WITH_NDBM)
# define FORMAT "NDBM"
#elif defined(WITH_OLD_DBM)
...
...
Please
register
or
sign in
to post a comment