1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

s3-readline: move cmd_history to smbclient, the only user.

Guenther
This commit is contained in:
Günther Deschner 2010-10-01 10:33:32 +02:00
parent b38d0542e1
commit 405b7d843f
3 changed files with 20 additions and 22 deletions

View File

@ -4006,6 +4006,26 @@ int cmd_iosize(void)
return 0;
}
/****************************************************************************
history
****************************************************************************/
static int cmd_history(void)
{
#if defined(HAVE_LIBREADLINE) && defined(HAVE_HISTORY_LIST)
HIST_ENTRY **hlist;
int i;
hlist = history_list();
for (i = 0; hlist && hlist[i]; i++) {
DEBUG(0, ("%d: %s\n", i, hlist[i]->line));
}
#else
DEBUG(0,("no history without readline support\n"));
#endif
return 0;
}
/* Some constants for completing filename arguments */

View File

@ -661,7 +661,6 @@ char *smb_readline(const char *prompt, void (*callback)(void),
char **(completion_fn)(const char *text, int start, int end));
const char *smb_readline_get_line_buffer(void);
void smb_readline_ca_char(char c);
int cmd_history(void);
/* The following definitions come from lib/recvfile.c */

View File

@ -172,24 +172,3 @@ void smb_readline_ca_char(char c)
rl_completion_append_character = c;
#endif
}
/****************************************************************************
history
****************************************************************************/
int cmd_history(void)
{
#if defined(HAVE_LIBREADLINE) && defined(HAVE_HISTORY_LIST)
HIST_ENTRY **hlist;
int i;
hlist = history_list();
for (i = 0; hlist && hlist[i]; i++) {
DEBUG(0, ("%d: %s\n", i, hlist[i]->line));
}
#else
DEBUG(0,("no history without readline support\n"));
#endif
return 0;
}