restructing...automake now used sql stuff working

This commit is contained in:
brianb
2001-04-11 23:33:19 +00:00
parent 58cb55ef0a
commit 12d830dc62
40 changed files with 6665 additions and 1852 deletions

View File

@@ -1,5 +1,7 @@
#include <stdio.h>
#include <readline.h>
#ifdef HAVE_READLINE
#include <readline/readline.h>
#endif
#include <string.h>
#include "mdbsql.h"
@@ -7,6 +9,30 @@ extern MdbSQL *g_sql;
char *g_input_ptr;
#ifndef HAVE_READLINE
char *readline(char *prompt)
{
char *buf, line[1000];
int i = 0;
printf("%s",prompt);
fgets(line,1000,stdin);
for (i=strlen(line);i>0;i--) {
if (line[i]=='\n') {
line[i]='\0';
break;
}
}
buf = (char *) malloc(strlen(line)+1);
strcpy(buf,line);
return buf;
}
add_history(char *s)
{
}
#endif
int mdb_sql_yyinput(char *buf, int need)
{
int cplen, have;