--- a/modules/berkeley-db/bdb.c +++ b/modules/berkeley-db/bdb.c @@ -351,40 +351,10 @@ DEFUN(BDB:DBE-CREATE,&key PASSWORD ENCRYPT :HOST CLIENT-TIMEOUT SERVER-TIMEOUT) { /* Create an environment handle */ DB_ENV *dbe, *dbe_cl; - bool remote_p = boundp(STACK_2); /* host ==> remote */ + if (boundp(STACK_2)) /* :HOST */ + error(error_condition, GETTEXT("RPC support has been dropped in Berkeley DB 5.1")); int cl_timeout = 0, sv_timeout = 0; -# if defined(DB_RPCCLIENT) /* 4.2 and later */ - SYSCALL(db_env_create,(&dbe,remote_p ? DB_RPCCLIENT : 0)); -# elif defined(DB_CLIENT) /* 4.1 and before */ - SYSCALL(db_env_create,(&dbe,remote_p ? DB_CLIENT : 0)); -# else -# error how does your Berkeley DB create a remote client? -# endif - if (remote_p) { - if (uint_p(STACK_0)) sv_timeout = I_to_uint(STACK_0); - if (uint_p(STACK_1)) cl_timeout = I_to_uint(STACK_1); - host_restart: - if (stringp(STACK_2)) { /* string host */ - with_string_0(STACK_2,GLO(misc_encoding),hostz, { - SYSCALL(dbe->set_rpc_server,(dbe,NULL,hostz,cl_timeout,sv_timeout,0)); - }); - } else if ((dbe_cl = (DB_ENV*)bdb_handle(STACK_2,`BDB::DBE`, - BH_NIL_IS_NULL))) { - /* reuse client */ - SYSCALL(dbe->set_rpc_server,(dbe,dbe_cl->cl_handle,NULL, - cl_timeout,sv_timeout,0)); - } else { /* bad host */ - pushSTACK(NIL); /* no PLACE */ - pushSTACK(STACK_(2+1)); /* TYPE-ERROR slot DATUM */ - pushSTACK(`(OR STRING BDB::DBE)`); /* TYPE-ERROR slot EXPECTED-TYPE */ - pushSTACK(STACK_2); /* host */ - pushSTACK(`BDB::DBE`); pushSTACK(S(string)); pushSTACK(S(Khost)); - pushSTACK(TheSubr(subr_self)->name); - check_value(type_error,GETTEXT("~S: ~S should be a ~S or a ~S, not ~S")); - STACK_2 = value1; - goto host_restart; - } - } + SYSCALL(db_env_create,(&dbe,0)); if (!missingp(STACK_4)) /* :PASSWD */ dbe_set_encryption(dbe,&STACK_3,&STACK_4); skipSTACK(5);