|
From: Jason C. <co...@cc...> - 2005-08-11 11:47:47
|
Dear Valgrind Users, I am using valgrind 2.4.1 (excellent tool - thanks) - have also tried 3.0 but get the same thing on a suse linux box (9.2) - here's the kernel gen: Linux vali 2.4.21-243-smp4G #1 SMP Thu Aug 12 15:32:27 UTC 2004 i686 i686 i386 GNU/Linux and I get a pair of messages in the following form ==22671== Warning: invalid file descriptor -1 in syscall close() ==22671== Warning: invalid file descriptor -2 in syscall close() . . a bit of output, then . ==22671== Invalid free() / delete / delete[] ==22671== at 0x3414CA69: free (vg_replace_malloc.c:152) ==22671== by 0x3530C03B: free_mem (in /lib/i686/libc.so.6) ==22671== by 0x3530BD71: __libc_freeres (in /lib/i686/libc.so.6) ==22671== by 0x341469D3: _vgw(float, long double,...)(...)(long double,...)(short) (vg_intercept.c:55) ==22671== by 0x34264BE7: IPC::run(DBManager&, int) (ipc.cpp:565) ==22671== by 0x805BEDF: server() (server.cpp:196) ==22671== by 0x805A889: main (main.cpp:88) ==22671== Address 0x3532F588 is not stack'd, malloc'd or (recently) free'd ==22671== ==22671== ERROR SUMMARY: 2 errors from 1 contexts (suppressed: 0 from 0) I can suppress the 'free_mem' message using --run-libc-freeres=no ( Although I'd like to know why I get it ;*) but I still get the file descriptor warnings. I searched through various pages and found a bug fixed report in the NEWS file 97427 "Warning: invalid file descriptor -1 in syscall close()" ... but frustratingly cant find what that pertains to ... is there any way I can easily locate where the invalid file descriptor warning is coming from (so I can prevent the invalid call?) Jason |