From: drh Date: Mon, 25 Sep 2006 13:48:30 +0000 (+0000) Subject: Bug fix in pragma table_info(). (CVS 3440) X-Git-Tag: version-3.6.10~2727 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6f8359865d0bd2c8e8491c253934bfd720658519;p=thirdparty%2Fsqlite.git Bug fix in pragma table_info(). (CVS 3440) FossilOrigin-Name: c037403bae0d78f9dd2703ff05cc3cd3ac54e062 --- diff --git a/manifest b/manifest index 12f0ec7c93..8ab975f673 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Remove\slegacy\scruft\sfrom\sshell.c.\s(CVS\s3439) -D 2006-09-25T13:09:23 +C Bug\sfix\sin\spragma\stable_info().\s(CVS\s3440) +D 2006-09-25T13:48:30 F Makefile.in cabd42d34340f49260bc2a7668c38eba8d4cfd99 F Makefile.linux-gcc 2d8574d1ba75f129aba2019f0b959db380a90935 F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028 @@ -79,7 +79,7 @@ F src/os_win.h 41a946bea10f61c158ce8645e7646b29d44f122b F src/pager.c 0f966f7fa225c377da2021fbbfdd50a48d877000 F src/pager.h 0cff9de5e9019cb695a04d18df8caaaff933a272 F src/parse.y 8c79a1debbd92a4f5609511e9bf0222de78f5ecb -F src/pragma.c dcb79b8170231f3aed99d4004b4d0a0fc14c4b4d +F src/pragma.c eac5926df7e10b68fd6ff7bb9188fb296883502c F src/prepare.c 3d9a1bb0644e8bccb3b78cb0833d269719237f4e F src/printf.c b179b6ed12f793e028dd169e2e2e2b2a37eedc63 F src/random.c d40f8d356cecbd351ccfab6eaedd7ec1b54f5261 @@ -399,7 +399,7 @@ F www/tclsqlite.tcl bb0d1357328a42b1993d78573e587c6dcbc964b9 F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0 F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b F www/whentouse.tcl 97e2b5cd296f7d8057e11f44427dea8a4c2db513 -P 20d7b29443ea7d9ec1ef81219c74ba725e8711e3 -R 60510ec2b80e60b23c8e8f8a7bf4e900 +P 815d8f84b317d26a3ca87405d27376e1e4493d8b +R 871ac05fe83e4a84b72b5166004ffd47 U drh -Z f2443117c38a4d8a389c6ba3feada653 +Z cbd41848a05680adddcda293356aa0eb diff --git a/manifest.uuid b/manifest.uuid index 61ae861c01..1e9d6ce8da 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -815d8f84b317d26a3ca87405d27376e1e4493d8b \ No newline at end of file +c037403bae0d78f9dd2703ff05cc3cd3ac54e062 \ No newline at end of file diff --git a/src/pragma.c b/src/pragma.c index 85374e79e5..28816a390d 100644 --- a/src/pragma.c +++ b/src/pragma.c @@ -11,7 +11,7 @@ ************************************************************************* ** This file contains code used to implement the PRAGMA command. ** -** $Id: pragma.c,v 1.122 2006/08/14 14:23:42 drh Exp $ +** $Id: pragma.c,v 1.123 2006/09/25 13:48:30 drh Exp $ */ #include "sqliteInt.h" #include "os.h" @@ -490,7 +490,11 @@ void sqlite3Pragma( pCol->zType ? pCol->zType : "", 0); sqlite3VdbeAddOp(v, OP_Integer, pCol->notNull, 0); pDflt = pCol->pDflt ? &pCol->pDflt->span : &noDflt; - sqlite3VdbeOp3(v, OP_String8, 0, 0, (char*)pDflt->z, pDflt->n); + if( pDflt->z ){ + sqlite3VdbeOp3(v, OP_String8, 0, 0, (char*)pDflt->z, pDflt->n); + }else{ + sqlite3VdbeAddOp(v, OP_Null, 0, 0); + } sqlite3VdbeAddOp(v, OP_Integer, pCol->isPrimKey, 0); sqlite3VdbeAddOp(v, OP_Callback, 6, 0); }