怎么排查这些内存泄漏

v_023 2009-07-20 09:37:02
查了很久看不出哪里的问题,试了很多办法依然无招,希望各位高手帮忙

Detected memory leaks!
Dumping objects ->
{287} normal block at 0x00D5BDA0, 8 bytes long.
Data: < H > 00 BD D5 00 48 BD D5 00
{277} normal block at 0x00D5BD00, 8 bytes long.
Data: <h > 68 B8 D5 00 20 BC D5 00
{266} normal block at 0x00D5B868, 8 bytes long.
Data: < > 00 00 00 00 10 B8 D5 00
{263} normal block at 0x00D5B8F8, 512 bytes long.
Data: < > 20 00 20 00 20 00 20 00 20 00 20 00 20 00 20 00
{258} normal block at 0x00D5B7A0, 52 bytes long.
Data: < > D0 F9 86 00 02 00 00 00 00 00 00 00 00 00 00 00
sockcore.cpp(89) : {109} client block at 0x00D56498, subtype c0, 28 bytes long.
a CPtrList object at $00D56498, 28 bytes long
sockcore.cpp(87) : {108} client block at 0x00D56440, subtype c0, 28 bytes long.
a CMapPtrToPtr object at $00D56440, 28 bytes long
sockcore.cpp(85) : {107} client block at 0x00D563E8, subtype c0, 28 bytes long.
a CMapPtrToPtr object at $00D563E8, 28 bytes long
{102} normal block at 0x00D56228, 80 bytes long.
Data: <ABCDEFGHIJKLMNOP> 41 42 43 44 45 46 47 48 49 4A 4B 4C 4D 4E 4F 50
{101} normal block at 0x00D561B8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{100} normal block at 0x00D56148, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{99} normal block at 0x00D560D8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{98} normal block at 0x00D56068, 48 bytes long.
Data: <urn:ietf:params:> 75 72 6E 3A 69 65 74 66 3A 70 61 72 61 6D 73 3A
{97} normal block at 0x00D55FF8, 48 bytes long.
Data: <urn:ietf:params:> 75 72 6E 3A 69 65 74 66 3A 70 61 72 61 6D 73 3A
{96} normal block at 0x00D53518, 48 bytes long.
Data: <urn:ietf:params:> 75 72 6E 3A 69 65 74 66 3A 70 61 72 61 6D 73 3A
{95} normal block at 0x00D534B8, 32 bytes long.
Data: <urn:ietf:params:> 75 72 6E 3A 69 65 74 66 3A 70 61 72 61 6D 73 3A
{94} normal block at 0x00D53448, 48 bytes long.
Data: <urn:ietf:params:> 75 72 6E 3A 69 65 74 66 3A 70 61 72 61 6D 73 3A
{93} normal block at 0x00D533D8, 48 bytes long.
Data: <urn:ietf:params:> 75 72 6E 3A 69 65 74 66 3A 70 61 72 61 6D 73 3A
{92} normal block at 0x00D53368, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{91} normal block at 0x00D532F8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{90} normal block at 0x00D53288, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{89} normal block at 0x00D53218, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{88} normal block at 0x00D531A8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{87} normal block at 0x00D53138, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{86} normal block at 0x00D530C8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{85} normal block at 0x00D53068, 32 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{84} normal block at 0x00D52FF8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{83} normal block at 0x00D52F78, 64 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{82} normal block at 0x00D52F18, 32 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{81} normal block at 0x00D52EB8, 32 bytes long.
Data: <roster:delimiter> 72 6F 73 74 65 72 3A 64 65 6C 69 6D 69 74 65 72
{80} normal block at 0x00D52508, 32 bytes long.
Data: <storage:rosterno> 73 74 6F 72 61 67 65 3A 72 6F 73 74 65 72 6E 6F
{79} normal block at 0x00D524A8, 32 bytes long.
Data: <storage:bookmark> 73 74 6F 72 61 67 65 3A 62 6F 6F 6B 6D 61 72 6B
{78} normal block at 0x00D52448, 32 bytes long.
Data: <vcard-temp:x:upd> 76 63 61 72 64 2D 74 65 6D 70 3A 78 3A 75 70 64
{76} normal block at 0x00D52C18, 32 bytes long.
Data: <jabber:x:encrypt> 6A 61 62 62 65 72 3A 78 3A 65 6E 63 72 79 70 74
{75} normal block at 0x00D52BB8, 32 bytes long.
Data: <jabber:iq:search> 6A 61 62 62 65 72 3A 69 71 3A 73 65 61 72 63 68
{74} normal block at 0x00D52B58, 32 bytes long.
Data: <jabber:iq:privat> 6A 61 62 62 65 72 3A 69 71 3A 70 72 69 76 61 74
{73} normal block at 0x00D52AF8, 32 bytes long.
Data: <jabber:iq:privac> 6A 61 62 62 65 72 3A 69 71 3A 70 72 69 76 61 63
{72} normal block at 0x00D52A98, 32 bytes long.
Data: <jabber:iq:regist> 6A 61 62 62 65 72 3A 69 71 3A 72 65 67 69 73 74
{71} normal block at 0x00D52A38, 32 bytes long.
Data: <jabber:iq:versio> 6A 61 62 62 65 72 3A 69 71 3A 76 65 72 73 69 6F
{70} normal block at 0x00D529D8, 32 bytes long.
Data: <jabber:iq:roster> 6A 61 62 62 65 72 3A 69 71 3A 72 6F 73 74 65 72
{69} normal block at 0x00D52968, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{68} normal block at 0x00D528F8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{67} normal block at 0x00D52888, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{66} normal block at 0x00D52828, 32 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{65} normal block at 0x00D556F8, 32 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{64} normal block at 0x00D527B8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{63} normal block at 0x00D52748, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{62} normal block at 0x00D526D8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{61} normal block at 0x00D52668, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{60} normal block at 0x00D525F8, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{59} normal block at 0x00D52588, 48 bytes long.
Data: <http://jabber.or> 68 74 74 70 3A 2F 2F 6A 61 62 62 65 72 2E 6F 72
{58} normal block at 0x00D55698, 32 bytes long.
Data: <jabber:component> 6A 61 62 62 65 72 3A 63 6F 6D 70 6F 6E 65 6E 74
{57} normal block at 0x00D55F98, 32 bytes long.
Data: <jabber:component> 6A 61 62 62 65 72 3A 63 6F 6D 70 6F 6E 65 6E 74
Object dump complete.
Detected memory leaks!
Dumping objects ->
{287} normal block at 0x00D5BDA0, 8 bytes long.
Data: < H > 00 BD D5 00 48 BD D5 00
{277} normal block at 0x00D5BD00, 8 bytes long.
Data: <h > 68 B8 D5 00 20 BC D5 00
{266} normal block at 0x00D5B868, 8 bytes long.
Data: < > 00 00 00 00 10 B8 D5 00
{263} normal block at 0x00D5B8F8, 512 bytes long.
Data: < > 20 00 20 00 20 00 20 00 20 00 20 00 20 00 20 00
{258} normal block at 0x00D5B7A0, 52 bytes long.
Data: < > D0 F9 86 00 01 00 00 00 00 00 00 00 00 00 00 00
Object dump complete.
...全文
489 14 打赏 收藏 转发到动态 举报
写回复
用AI写文章
14 条回复
切换为时间正序
请发表友善的回复…
发表回复
v_023 2010-09-05
  • 打赏
  • 举报
回复
[Quote=引用 12 楼 zmx_project 的回复:]
我也出问题了,查不出来。麻烦哪位大虾帮忙看看,多谢了。
Visual Leak Detector detected 9 memory leaks.
Visual Leak Detector is now exiting.
Detected memory leaks!
Dumping objects ->
{16268} normal block at 0x05DD3CB8, 5 byte……
[/Quote]已经有爆出来哪里出错了哦
v_023 2010-09-05
  • 打赏
  • 举报
回复
D:\zmx26\zmxView.cpp(1664) : {15637} normal block at 0x0AD60040, 37748736 bytes long.
这个不是说明了问题所在么
zmx_project 2010-08-29
  • 打赏
  • 举报
回复

我也出问题了,查不出来。麻烦哪位大虾帮忙看看,多谢了。
Visual Leak Detector detected 9 memory leaks.
Visual Leak Detector is now exiting.
Detected memory leaks!
Dumping objects ->
{16268} normal block at 0x05DD3CB8, 5 bytes long.
Data: <true > 74 72 75 65 00
{16266} normal block at 0x05DD0F60, 6 bytes long.
Data: <false > 66 61 6C 73 65 00
{16264} normal block at 0x05DCD2D8, 1 bytes long.
Data: < > 00
{16258} normal block at 0x05DCD280, 24 bytes long.
Data: <`wL . > 60 77 4C 10 01 00 00 00 D8 D2 DC 05 2E 00 CD CD
{16251} normal block at 0x05D88F08, 8 bytes long.
Data: < xL > 08 78 4C 10 01 00 00 00
{16115} normal block at 0x05DC8D88, 512 bytes long.
Data: < > 20 00 20 00 20 00 20 00 20 00 20 00 20 00 20 00
{16098} normal block at 0x05D85108, 16 bytes long.
Data: <@wL > 40 77 4C 10 01 00 00 00 00 00 00 00 00 00 00 00
D:\zmx26\zmxView.cpp(1664) : {15637} normal block at 0x0AD60040, 37748736 bytes long.
Data: < > 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
{1034} normal block at 0x02711150, 36 bytes long.
Data: < oW > D8 6F 57 00 01 00 00 00 00 CD CD CD 01 00 00 00
{998} normal block at 0x0270D298, 31 bytes long.
Data: <vtkOpenGLVolumeT> 76 74 6B 4F 70 65 6E 47 4C 56 6F 6C 75 6D 65 54
{997} normal block at 0x0270D230, 31 bytes long.
Data: <vtkOpenGLVolumeT> 76 74 6B 4F 70 65 6E 47 4C 56 6F 6C 75 6D 65 54
{996} normal block at 0x0270D1C8, 35 bytes long.
Data: <vtkOpenGLRayCast> 76 74 6B 4F 70 65 6E 47 4C 52 61 79 43 61 73 74
{995} normal block at 0x0270D160, 38 bytes long.
Data: <vtkUnstructuredG> 76 74 6B 55 6E 73 74 72 75 63 74 75 72 65 64 47
{994} normal block at 0x0270D0F8, 39 bytes long.
Data: <vtkUnstructuredG> 76 74 6B 55 6E 73 74 72 75 63 74 75 72 65 64 47
{509} normal block at 0x02701310, 12 bytes long.
Data: <vtkImageFFT > 76 74 6B 49 6D 61 67 65 46 46 54 00
{507} normal block at 0x027012B8, 26 bytes long.
Data: <vtkImageExtractC> 76 74 6B 49 6D 61 67 65 45 78 74 72 61 63 74 43
{506} normal block at 0x02701260, 15 bytes long.
Data: <vtkImageExport > 76 74 6B 49 6D 61 67 65 45 78 70 6F 72 74 00
{505} normal block at 0x02701208, 25 bytes long.
Data: <vtkImageEuclidea> 76 74 6B 49 6D 61 67 65 45 75 63 6C 69 64 65 61
{504} normal block at 0x027011B0, 26 bytes long.
Data: <vtkImageEuclidea> 76 74 6B 49 6D 61 67 65 45 75 63 6C 69 64 65 61
{503} normal block at 0x02701158, 24 bytes long.
Data: <vtkImageEllipsoi> 76 74 6B 49 6D 61 67 65 45 6C 6C 69 70 73 6F 69
{502} normal block at 0x02701100, 19 bytes long.
Data: <vtkImageDotProdu> 76 74 6B 49 6D 61 67 65 44 6F 74 50 72 6F 64 75
{501} normal block at 0x027010A8, 19 bytes long.
Data: <vtkImageDivergen> 76 74 6B 49 6D 61 67 65 44 69 76 65 72 67 65 6E
{500} normal block at 0x02701050, 22 bytes long.
Data: <vtkImageDilateEr> 76 74 6B 49 6D 61 67 65 44 69 6C 61 74 65 45 72
{499} normal block at 0x02700FF8, 19 bytes long.
Data: <vtkImageDifferen> 76 74 6B 49 6D 61 67 65 44 69 66 66 65 72 65 6E
{498} normal block at 0x02700FA0, 21 bytes long.
Data: <vtkImageDataStre> 76 74 6B 49 6D 61 67 65 44 61 74 61 53 74 72 65
{497} normal block at 0x02700F48, 17 bytes long.
Data: <vtkImageCursor3D> 76 74 6B 49 6D 61 67 65 43 75 72 73 6F 72 33 44
The thread 0x3FC has exited with code 0 (0x0).
zmx_project 2010-08-29
  • 打赏
  • 举报
回复
在debug窗口中双击这一行“sockcore.cpp(89) : {109} client block at 0x00D56498, subtype c0, 28 bytes long.”可以跟踪到没释放内存的相关代码行。

 CRT 库对程序运行期间分配的所有内存块进行计数,包括由 CRT 库自己分配的内存和其它库(如 MFC)分配的内存。因此,分配序号为 N 的对象即为程序中分配的第 N 个对象,但不一定是代码分配的第 N 个对象。(大多数情况下并非如此。)这样的话,你便可以利用分配序号在分配内存的位置设置一个断点。方法是在程序起始附近设置一个位置断点。当程序在该点中断时,可以从 QuickWatch(快速监视)对话框或 Watch(监视)窗口设置一个内存分配断点:

  例如,在 Watch 窗口中,在 Name 栏键入下面的表达式:


_crtBreakAlloc


  如果要使用 CRT 库的多线程 DLL 版本(/MD 选项),那么必须包含上下文操作符,像这样:

{,,msvcrtd.dll}_crtBreakAlloc


  现在按下回车键,调试器将计算该值并把结果放入 Value 栏。如果没有在内存分配点设置任何断点,该值将为 –1。

  用你想要在其位置中断的内存分配的分配序号替换 Value 栏中的值。例如输入 109。这样就会在分配序号为109的地方中断。

  在所感兴趣的内存分配处设置断点后,可以继续调试。这时,运行程序时一定要小心,要保证内存块分配的顺序不会改变。当程序在指定的内存分配处中断时,可以查看 Call Stack(调用堆栈)窗口和其它调试器信息以确定分配内存时的情况。如果必要,可以从该点继续执行程序,以查看对象发生了什么情况,或许可以确定未正确释放对象的原因。

  尽管通常在调试器中设置内存分配断点更方便,但如果愿意,也可在代码中设置这些断点。为了在代码中设置一个内存分配断点,可以增加这样一行(对于第四十五个内存分配):


_crtBreakAlloc = 109;


  你还可以使用有相同效果的 _CrtSetBreakAlloc 函数:

_CrtSetBreakAlloc(109);


v_023 2009-07-20
  • 打赏
  • 举报
回复
在贴段用VLD检查出来的泄漏

WARNING: Visual Leak Detector detected memory leaks!
---------- Block 6540 at 0x00DAEA60: 36 bytes ----------
Call Stack:
0x0065197A (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA556 (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA409 (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA36F (File and line number not available): gloox::ClientBase::connectionImpl
0x00789873 (File and line number not available): gloox::ClientBase::connectionImpl
0x005C8AD2 (File and line number not available): gloox::ClientBase::connectionImpl
0x005C7E2A (File and line number not available): gloox::ClientBase::connectionImpl
0x005C4BE1 (File and line number not available): gloox::ClientBase::connectionImpl
0x006233AB (File and line number not available): gloox::ClientBase::connectionImpl
0x006A7A22 (File and line number not available): gloox::ClientBase::connectionImpl
0x006A7BDD (File and line number not available): gloox::ClientBase::connectionImpl
0x00671D5D (File and line number not available): gloox::ClientBase::connectionImpl
0x006BC5D0 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B4E9F (File and line number not available): gloox::ClientBase::connectionImpl
0x00712BC3 (File and line number not available): gloox::ClientBase::connectionImpl
0x007128C1 (File and line number not available): gloox::ClientBase::connectionImpl
0x00711CB2 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B5CE4 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B58C6 (File and line number not available): gloox::ClientBase::connectionImpl
0x0070F6B1 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B4675 (File and line number not available): gloox::ClientBase::connectionImpl
0x00626A7E (File and line number not available): gloox::ClientBase::connectionImpl
0x7C80B729 (File and line number not available): GetModuleFileNameA
Data:
60 EA DA 00 60 EA DA 00 CD CD CD CD CD CD CD CD `...`... ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD ........ ........

---------- Block 6539 at 0x015CCC48: 28 bytes ----------
Call Stack:
0x0065197A (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA556 (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA409 (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA36F (File and line number not available): gloox::ClientBase::connectionImpl
0x00789873 (File and line number not available): gloox::ClientBase::connectionImpl
0x0068339A (File and line number not available): gloox::ClientBase::connectionImpl
0x0067C2CE (File and line number not available): gloox::ClientBase::connectionImpl
0x00676B36 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B0BAB (File and line number not available): gloox::ClientBase::connectionImpl
0x006A7BAA (File and line number not available): gloox::ClientBase::connectionImpl
0x00671D5D (File and line number not available): gloox::ClientBase::connectionImpl
0x006BC5D0 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B4E9F (File and line number not available): gloox::ClientBase::connectionImpl
0x00712BC3 (File and line number not available): gloox::ClientBase::connectionImpl
0x007128C1 (File and line number not available): gloox::ClientBase::connectionImpl
0x00711CB2 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B5CE4 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B58C6 (File and line number not available): gloox::ClientBase::connectionImpl
0x0070F6B1 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B4675 (File and line number not available): gloox::ClientBase::connectionImpl
0x00626A7E (File and line number not available): gloox::ClientBase::connectionImpl
0x7C80B729 (File and line number not available): GetModuleFileNameA
Data:
48 CC 5C 01 48 CC 5C 01 CD CD CD CD CD CD CD CD H.\.H.\. ........
CD CD CD CD CD CD CD CD CD CD CD CD ........ ........

---------- Block 6538 at 0x015B3888: 212 bytes ----------
Call Stack:
0x0065197A (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA556 (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA409 (File and line number not available): gloox::ClientBase::connectionImpl
0x005FA36F (File and line number not available): gloox::ClientBase::connectionImpl
0x00789873 (File and line number not available): gloox::ClientBase::connectionImpl
0x0068322D (File and line number not available): gloox::ClientBase::connectionImpl
0x0067BF4E (File and line number not available): gloox::ClientBase::connectionImpl
0x006767A6 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B0ABB (File and line number not available): gloox::ClientBase::connectionImpl
0x006A7B9B (File and line number not available): gloox::ClientBase::connectionImpl
0x00671D5D (File and line number not available): gloox::ClientBase::connectionImpl
0x006BC5D0 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B4E9F (File and line number not available): gloox::ClientBase::connectionImpl
0x00712BC3 (File and line number not available): gloox::ClientBase::connectionImpl
0x007128C1 (File and line number not available): gloox::ClientBase::connectionImpl
0x00711CB2 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B5CE4 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B58C6 (File and line number not available): gloox::ClientBase::connectionImpl
0x0070F6B1 (File and line number not available): gloox::ClientBase::connectionImpl
0x006B4675 (File and line number not available): gloox::ClientBase::connectionImpl
0x00626A7E (File and line number not available): gloox::ClientBase::connectionImpl
0x7C80B729 (File and line number not available): GetModuleFileNameA
Data:
88 38 5B 01 88 38 5B 01 CD CD CD CD CD CD CD CD .8[..8[. ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD ........ ........

v_023 2009-07-20
  • 打赏
  • 举报
回复
上面有一部分是CRT检测出来的内存泄漏,还有一部分是VS编译器自己检查出来的,一般都有出现对应内存泄漏页面,这样也好检测,但是现在没有页面了,只有泄漏块地址和泄漏的大小,但是还是不清楚哪里的问题,复查了好几遍源代码了
lingyin55 2009-07-20
  • 打赏
  • 举报
回复
建议看下《WINDOWS程序调试》中有关内存泄漏的那几个小节。
taodm 2009-07-20
  • 打赏
  • 举报
回复
楼主是怎么定义什么算“内存泄漏”的?
hhyttppd 2009-07-20
  • 打赏
  • 举报
回复
另外你可以下内存断点。
bigriverhorse 2009-07-20
  • 打赏
  • 举报
回复
如果是必现的话,就按文件名+变量名单步调试一下就可以了,比如下面这个:


sockcore.cpp(89) : {109} client block at 0x00D56498, subtype c0, 28 bytes long.
a CPtrList object at $00D56498, 28 bytes long
DarkChampion 2009-07-20
  • 打赏
  • 举报
回复
mark
v_023 2009-07-20
  • 打赏
  • 举报
回复
用了但是什么也没有检查出来,是不是要设置什么
beyond071 2009-07-20
  • 打赏
  • 举报
回复
有时候未必是真的内存泄漏了,而是你的内存在检测模块释放后才被释放。
hhyttppd 2009-07-20
  • 打赏
  • 举报
回复
BoundsChecker

64,685

社区成员

发帖
与我相关
我的任务
社区描述
C++ 语言相关问题讨论,技术干货分享,前沿动态等
c++ 技术论坛(原bbs)
社区管理员
  • C++ 语言社区
  • encoderlee
  • paschen
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
  1. 请不要发布与C++技术无关的贴子
  2. 请不要发布与技术无关的招聘、广告的帖子
  3. 请尽可能的描述清楚你的问题,如果涉及到代码请尽可能的格式化一下

试试用AI创作助手写篇文章吧