中輸入的數據我希望安全地刪除(甚至是內存中的跟蹤)任何用戶輸入到文本框中的數據。我想知道是否將它設置爲""
足夠安全。 SetWindowText
是Win32 API中的函數,位於user32.dll。在WIN32 GDI中使用SetWindowText,並安全地刪除在
在節目:
SetWindowText(myHandle, "Hello");
SetWindowText(myHandle, "Goodbye");
//Was the buffer containing chars "Hello" overwritten by the
//series of chars "Goodb"?
//Or was another chunk of buffer being allocated to store "Goodbye",
//hence "Hello" still exist somewhere in the memory?
SetWindowText(myHandle, "");
//What does Windows do to the buffer that used to store chars "Goodbye"?
//Does it wipe out and replace the data in the buffer to all 0s here?
//Or does "Goodbye" actually still stays in the memory?
你可能意思是「你好」(雙引號) – MSalters 2010-10-27 08:58:32