/ Check-in [4507f0b3]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

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

Overview
Comment:Fix the showdb utility so that it displays the correct secondary usage of a page when reporting on an error of a page being used more than once.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 4507f0b3d409cd14bb2b9c29c92c76aa3ccb22b6
User & Date: drh 2013-02-19 20:25:16
Context
2013-02-19
22:26
Enhance the showdb tool with options to show PTRMAP usage and content. check-in: 06bd9130 user: drh tags: trunk
20:25
Fix the showdb utility so that it displays the correct secondary usage of a page when reporting on an error of a page being used more than once. check-in: 4507f0b3 user: drh tags: trunk
18:45
Enhance the pgidx of the showdb utility so that it provides better information even if the sqlite_master table is corrupt. check-in: d14263a7 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to tool/showdb.c.

475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
            pgno, mxPage, zMsg);
    sqlite3_free(zMsg);
    return;
  }
  if( zPageUse[pgno]!=0 ){
    printf("ERROR: page %d used multiple times:\n", pgno);
    printf("ERROR:    previous: %s\n", zPageUse[pgno]);
    printf("ERROR:    current:  %s\n", zPageUse[pgno]);
    sqlite3_free(zPageUse[pgno]);
  }
  zPageUse[pgno] = zMsg;
}

/*
** Find overflow pages of a cell and describe their usage.







|







475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
            pgno, mxPage, zMsg);
    sqlite3_free(zMsg);
    return;
  }
  if( zPageUse[pgno]!=0 ){
    printf("ERROR: page %d used multiple times:\n", pgno);
    printf("ERROR:    previous: %s\n", zPageUse[pgno]);
    printf("ERROR:    current:  %s\n", zMsg);
    sqlite3_free(zPageUse[pgno]);
  }
  zPageUse[pgno] = zMsg;
}

/*
** Find overflow pages of a cell and describe their usage.