0
C++ print value memory
if i write a program A that store a variable to heap. //program that name ABC #include <unistd.h> int x = new int; *x = 5; cout << x; //print memory address usleep(5000000) //make the program wait if the output is 0x7529 then is it possible to print the 0x7529 value from another program while the ABC program waiting? if yes how?
4 Answers
+ 2
http://www.boost.org/doc/libs/1_49_0/doc/html/interprocess/sharedmemorybetweenprocesses.html
https://stackoverflow.com/questions/31455200/get-the-address-of-a-variable-in-another-process
https://stackoverflow.com/questions/15649926/accesing-values-of-another-program
https://stackoverflow.com/questions/4911994/sharing-a-global-static-variable-between-a-process-and-dll
https://stackoverflow.com/questions/847313/how-to-read-3rd-party-applications-variables-from-memory
0
those sites is having a complex code. i just need the simple code
0
This can't be achieved simply. Simple answer - it can't be done by obeying all the rules.
0
i just getting started with c++. i will learn it later. thanx for your response