From: Sven Hoexter Date: Mon, 22 Sep 2014 16:12:59 +0000 (+0200) Subject: Imported Upstream version 3.052 X-Git-Tag: upstream/3.052^0 X-Git-Url: https://git.sven.stormbind.net/?a=commitdiff_plain;h=0a085bb35433261a474838231960d8ee3dc31d5c;p=sven%2Fmysqltcl.git Imported Upstream version 3.052 --- diff --git a/ChangeLog b/ChangeLog index f9aa6ff..8a337fe 100755 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,5 @@ +Release 3.052 +-- fix multiresult bug (column number) (patch from Thikrallah I.Shreah) Release 3.051 -- add connection option -reconnect (patch from david cluytens) Release 3.05 diff --git a/configure b/configure index ac14037..33c672f 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.68 for mysqltcl 3.051. +# Generated by GNU Autoconf 2.68 for mysqltcl 3.052. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -557,8 +557,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='mysqltcl' PACKAGE_TARNAME='mysqltcl' -PACKAGE_VERSION='3.051' -PACKAGE_STRING='mysqltcl 3.051' +PACKAGE_VERSION='3.052' +PACKAGE_STRING='mysqltcl 3.052' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1276,7 +1276,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures mysqltcl 3.051 to adapt to many kinds of systems. +\`configure' configures mysqltcl 3.052 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1337,7 +1337,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of mysqltcl 3.051:";; + short | recursive ) echo "Configuration of mysqltcl 3.052:";; esac cat <<\_ACEOF @@ -1441,7 +1441,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -mysqltcl configure 3.051 +mysqltcl configure 3.052 generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. @@ -1806,7 +1806,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by mysqltcl $as_me 3.051, which was +It was created by mysqltcl $as_me 3.052, which was generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -8073,7 +8073,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by mysqltcl $as_me 3.051, which was +This file was extended by mysqltcl $as_me 3.052, which was generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -8126,7 +8126,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -mysqltcl config.status 3.051 +mysqltcl config.status 3.052 configured by $0, generated by GNU Autoconf 2.68, with options \\"\$ac_cs_config\\" diff --git a/configure.in b/configure.in index 214aa3c..1a248ce 100755 --- a/configure.in +++ b/configure.in @@ -19,7 +19,7 @@ dnl to configure the system for the local environment. # so you can encode the package version directly into the source files. #----------------------------------------------------------------------- -AC_INIT([mysqltcl], [3.051]) +AC_INIT([mysqltcl], [3.052]) #-------------------------------------------------------------------- # Call TEA_INIT as the first TEA_ macro to set up initial vars. diff --git a/generic/mysqltcl.c b/generic/mysqltcl.c index 1269e85..53195b9 100755 --- a/generic/mysqltcl.c +++ b/generic/mysqltcl.c @@ -36,7 +36,7 @@ #ifdef _WINDOWS #include #define PACKAGE "mysqltcl" - #define PACKAGE_VERSION "3.051" + #define PACKAGE_VERSION "3.052" #endif #include @@ -2163,6 +2163,7 @@ static int Mysqltcl_NextResult(ClientData clientData, Tcl_Interp *interp, int ob return mysql_server_confl(interp,objc,objv,handle->connection); } handle->result = mysql_store_result(handle->connection); + handle->col_count = mysql_num_fields(handle->result); if (handle->result == NULL) { Tcl_SetObjResult(interp, Tcl_NewIntObj(-1)); } else { @@ -2767,4 +2768,4 @@ int Mysqltcl_SafeInit(interp) { return Mysqltcl_Init(interp); } - + diff --git a/tests/libload.tcl b/tests/libload.tcl index 66a71dd..d059465 100755 --- a/tests/libload.tcl +++ b/tests/libload.tcl @@ -1,4 +1,4 @@ -set file libmysqltcl3.05 +set file libmysqltcl3.052 if {[file exists ./${file}[info sharedlibextension]]} { load ./${file}[info sharedlibextension] diff --git a/tests/test41.tcl b/tests/test41.tcl index 399f443..fd78ad8 100755 --- a/tests/test41.tcl +++ b/tests/test41.tcl @@ -190,6 +190,18 @@ tcltest::test {nextresult-1.0} {only one result} -body { return $hadRow } -result 1 -returnCodes 2 +tcltest::test {nextresult-rows-1.1} {rows number} -body { + mysql::ping $conn + mysql::sel $conn { + select name from Student where name='Sojka'; + select name,semester from Student; + } + set r1 [mysql::result $conn cols] + mysql::nextresult $conn + set r2 [mysql::result $conn cols] + expr {$r1+$r2} +} -result 3 + tcltest::test {setserveroption-1.0} {set multistatment off} -body { mysql::setserveroption $conn -multi_statment_off mysql::exec $conn {