diff --git a/src/modules/Odbc/odbc.c b/src/modules/Odbc/odbc.c index 672fd40ab58e9984e0254df395089105a7a7079f..d6f3f40ebe00b40a31bba76a1e6756c53f7d30ce 100644 --- a/src/modules/Odbc/odbc.c +++ b/src/modules/Odbc/odbc.c @@ -1,5 +1,5 @@ /* - * $Id: odbc.c,v 1.15 1999/03/24 02:00:08 marcus Exp $ + * $Id: odbc.c,v 1.16 1999/06/01 21:04:18 grubba Exp $ * * Pike interface to ODBC compliant databases. * @@ -16,7 +16,7 @@ #include "config.h" #endif /* HAVE_CONFIG_H */ -RCSID("$Id: odbc.c,v 1.15 1999/03/24 02:00:08 marcus Exp $"); +RCSID("$Id: odbc.c,v 1.16 1999/06/01 21:04:18 grubba Exp $"); #include "interpret.h" #include "object.h" @@ -203,14 +203,25 @@ static void f_create(INT32 args) * database argument is ignored */ - if (!pwd) { - pwd = make_shared_string(""); + if (!server) { + push_constant_text("default"); + server = sp[-1].u.string; + args++; + } + if (!database) { + push_constant_text(""); + database = sp[-1].u.string; + args++; } if (!user) { - user = make_shared_string(""); + push_constant_text(""); + user = sp[-1].u.string; + args++; } - if (!server) { - server = make_shared_string("default"); + if (!pwd) { + push_constant_text(""); + pwd = sp[-1].u.string; + args++; } if (PIKE_ODBC->flags & PIKE_ODBC_CONNECTED) { PIKE_ODBC->flags &= ~PIKE_ODBC_CONNECTED;