Add DEFAULT_EDITOR to ldapconfig.h. Used by ldbmtest and ud.

This commit is contained in:
Kurt Zeilenga 1999-03-17 22:34:17 +00:00
parent 1676d61130
commit 5a4babde00
2 changed files with 4 additions and 4 deletions

View File

@ -39,6 +39,8 @@
#define DEFAULT_LIBEXECDIR "%LIBEXECDIR%"
#define DEFAULT_RUNDIR "%RUNDIR%"
#define DEFAULT_EDITOR "%EDITOR%"
#define DEFAULT_LDAP_CONF_FILE "%SYSCONFDIR%/ldap.conf"
#define DEFAULT_LDAP_USERRC_FILE "ldaprc"
#define DEFAULT_LDAP_ENV_PREFIX "LDAP"
@ -178,7 +180,7 @@ Please try again later.\r\n"
/* ud configuration file */
#define UD_CONFIG_FILE "%SYSCONFDIR%/ud.conf"
/* default editor */
#define UD_DEFAULT_EDITOR "%EDITOR%"
#define UD_DEFAULT_EDITOR DEFAULT_EDITOR
/* default bbasename of user config file */
#define UD_USER_CONFIG_FILE ".udrc"
/* default base where groups are created */

View File

@ -31,8 +31,6 @@
#include "../slap.h"
#include "../back-ldbm/back-ldbm.h"
#define EDITOR "/usr/ucb/vi"
static struct dbcache *openchoice(char c, int mode, int verbose, char **fname);
static void print_entry(FILE *fp, char c, Datum *key, char *klabel, Datum *data, char *dlabel);
static void free_and_close(struct dbcache *dbc, Datum key, Datum data);
@ -537,7 +535,7 @@ edit_entry( char c, Datum *data )
char *editor;
if ( (editor = getenv( "EDITOR" )) == NULL ) {
editor = EDITOR;
editor = DEFAULT_EDITOR;
}
execl( editor, editor, tmpname, NULL );
perror( "execl" );