--- [EMAIL PROTECTED] wrote:
> It appears that you are in fact running /bin/bash, > not > SQLite, and finding memory leaks there. Perhaps > "sqlite3" > is really a shell script on your system. Try > running > valgrind on a real sqlite3 executable and I believe > you > will find that there are no memory leaks. > -- > D. Richard Hipp <[EMAIL PROTECTED]> > > Execuse me for my wrong with wrong sqlite3, Here is the real binary sqlite3 in valgrind, and I has NOT defined SQLITE_ENABLE_MEMORY_MANAGEMENT : [EMAIL PROTECTED] /data/lfs/sqlite-3.3.6/.libs]# valgrind --leak-check=full ./sqlite3 ==28654== Memcheck, a memory error detector. ==28654== Copyright (C) 2002-2005, and GNU GPL'd, by Julian Seward et al. ==28654== Using LibVEX rev 1575, a library for dynamic binary translation. ==28654== Copyright (C) 2004-2005, and GNU GPL'd, by OpenWorks LLP. ==28654== Using valgrind-3.1.1, a dynamic binary instrumentation framework. ==28654== Copyright (C) 2000-2005, and GNU GPL'd, by Julian Seward et al. ==28654== For more details, rerun with: -v ==28654== SQLite version 3.2.2 Enter ".help" for instructions sqlite> .exit ==28654== ==28654== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 19 from 2) ==28654== malloc/free: in use at exit: 53,786 bytes in 322 blocks. ==28654== malloc/free: 487 allocs, 165 frees, 67,138 bytes allocated. ==28654== For counts of detected errors, rerun with: -v ==28654== searching for pointers to 322 not-freed blocks. ==28654== checked 142,284 bytes. ==28654== ==28654== 6 bytes in 1 blocks are possibly lost in loss record 2 of 14 ==28654== at 0x401B46D: malloc (vg_replace_malloc.c:149) ==28654== by 0x804C4DB: find_home_dir (shell.c:1553) ==28654== by 0x804C9EB: main (shell.c:1779) ==28654== ==28654== ==28654== 25 bytes in 1 blocks are definitely lost in loss record 6 of 14 ==28654== at 0x401B46D: malloc (vg_replace_malloc.c:149) ==28654== by 0x804CA10: main (shell.c:1780) ==28654== ==28654== ==28654== 40 bytes in 2 blocks are definitely lost in loss record 7 of 14 ==28654== at 0x401B46D: malloc (vg_replace_malloc.c:149) ==28654== by 0x4153FB9: xmalloc (in /usr/lib/libreadline.so.4.3) ==28654== by 0x41575EC: sh_set_lines_and_columns (in /usr/lib/libreadline.so.4.3) ==28654== by 0x4150AAE: _rl_get_screen_size (in /usr/lib/libreadline.so.4.3) ==28654== by 0x415114C: _rl_init_terminal_io (in /usr/lib/libreadline.so.4.3) ==28654== by 0x413FA77: rl_initialize (in /usr/lib/libreadline.so.4.3) ==28654== by 0x413FC42: readline (in /usr/lib/libreadline.so.4.3) ==28654== by 0x804A988: process_input (shell.c:198) ==28654== by 0x804CA3E: main (shell.c:1786) ==28654== ==28654== LEAK SUMMARY: ==28654== definitely lost: 65 bytes in 3 blocks. ==28654== possibly lost: 6 bytes in 1 blocks. ==28654== still reachable: 53,715 bytes in 318 blocks. ==28654== suppressed: 0 bytes in 0 blocks. ==28654== Reachable blocks (those to which a pointer was found) are not shown. ==28654== To see them, rerun with: --show-reachable=yes [EMAIL PROTECTED] /data/lfs/sqlite-3.3.6/.libs]# ___________________________________________________________ Mp3疯狂搜-新歌热歌高速下 http://music.yahoo.com.cn/?source=mail_mailbox_footer