/ Check-in [c419955d]
Login

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

Overview
Comment:Remove duplicated assignment in realloc.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: c419955df0ad0507ecb3869786d48458366d4e8f
User & Date: shaneh 2010-02-16 22:06:31
Context
2010-02-17
03:57
More rounding tests. check-in: 3863638b user: shaneh tags: trunk
2010-02-16
22:06
Remove duplicated assignment in realloc. check-in: c419955d user: shaneh tags: trunk
22:00
Added additional rounding tests. check-in: b8ee76bc user: shaneh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Show Whitespace Changes Patch

Changes to src/mem1.c.

    71     71   ** cases where nByte<=0 will have been intercepted by higher-level
    72     72   ** routines and redirected to xFree.
    73     73   */
    74     74   static void *sqlite3MemRealloc(void *pPrior, int nByte){
    75     75     sqlite3_int64 *p = (sqlite3_int64*)pPrior;
    76     76     assert( pPrior!=0 && nByte>0 );
    77     77     nByte = ROUND8(nByte);
    78         -  p = (sqlite3_int64*)pPrior;
    79     78     p--;
    80     79     p = realloc(p, nByte+8 );
    81     80     if( p ){
    82     81       p[0] = nByte;
    83     82       p++;
    84     83     }
    85     84     return (void*)p;