/ Check-in [734dde76]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix for bug #7: Correctly display the P3 operand in a VDBE trace when the operand is really a pointer to a structure. (CVS 512)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 734dde765b38d61feaa5520e6481c77022367892
User & Date: drh 2002-04-02 01:44:51
Context
2002-04-02
01:58
Fix for bug #6: Correctly handle functions in the WHERE clause of a join. (CVS 513) check-in: bdd8ce58 user: drh tags: trunk
01:44
Fix for bug #7: Correctly display the P3 operand in a VDBE trace when the operand is really a pointer to a structure. (CVS 512) check-in: 734dde76 user: drh tags: trunk
2002-04-01
12:15
Remove from the index page of the website hyperlinks that are not directly related to SQLite. (CVS 511) check-in: 0cb5cfa8 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/vdbe.c.

    26     26   ** type to the other occurs as necessary.
    27     27   ** 
    28     28   ** Most of the code in this file is taken up by the sqliteVdbeExec()
    29     29   ** function which does the work of interpreting a VDBE program.
    30     30   ** But other routines are also provided to help in building up
    31     31   ** a program instruction by instruction.
    32     32   **
    33         -** $Id: vdbe.c,v 1.135 2002/03/18 13:03:55 drh Exp $
           33  +** $Id: vdbe.c,v 1.136 2002/04/02 01:44:51 drh Exp $
    34     34   */
    35     35   #include "sqliteInt.h"
    36     36   #include <ctype.h>
    37     37   
    38     38   /*
    39     39   ** The following global variable is incremented every time a cursor
    40     40   ** moves, either by the OP_MoveTo or the OP_Next opcode.  The test
................................................................................
  1296   1296         break;
  1297   1297       }
  1298   1298   
  1299   1299       /* Only allow tracing if NDEBUG is not defined.
  1300   1300       */
  1301   1301   #ifndef NDEBUG
  1302   1302       if( p->trace ){
         1303  +      char *zP3;
         1304  +      char zPtr[40];
         1305  +      if( pOp->p3type==P3_POINTER ){
         1306  +        sprintf(zPtr, "ptr(%#x)", (int)pOp->p3);
         1307  +        zP3 = zPtr;
         1308  +      }else{
         1309  +        zP3 = pOp->p3;
         1310  +      }
  1303   1311         fprintf(p->trace,"%4d %-12s %4d %4d %s\n",
  1304         -        pc, zOpName[pOp->opcode], pOp->p1, pOp->p2,
  1305         -           pOp->p3 ? pOp->p3 : "");
         1312  +        pc, zOpName[pOp->opcode], pOp->p1, pOp->p2, zP3 ? zP3 : "");
  1306   1313         fflush(p->trace);
  1307   1314       }
  1308   1315   #endif
  1309   1316   
  1310   1317       switch( pOp->opcode ){
  1311   1318   
  1312   1319   /*****************************************************************************