summaryrefslogtreecommitdiff
path: root/source3/client/client.c
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-10-01 10:33:32 +0200
committerGünther Deschner <gd@samba.org>2010-10-01 22:30:22 +0200
commit405b7d843f9103a29e923892337472e0fd891037 (patch)
tree82f123f07602adf1ce54866984e7579d5dd0c1a3 /source3/client/client.c
parentb38d0542e193512796d5d9502ac8d688a1036157 (diff)
downloadsamba-405b7d843f9103a29e923892337472e0fd891037.tar.gz
samba-405b7d843f9103a29e923892337472e0fd891037.tar.bz2
samba-405b7d843f9103a29e923892337472e0fd891037.zip
s3-readline: move cmd_history to smbclient, the only user.
Guenther
Diffstat (limited to 'source3/client/client.c')
-rw-r--r--source3/client/client.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/source3/client/client.c b/source3/client/client.c
index 1432d95c22..e79ea16191 100644
--- a/source3/client/client.c
+++ b/source3/client/client.c
@@ -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 */