title: How to inject code into a running process using C/C++
body: <p>I am looking for advice on how to manipulate functions by injecting code directly into memory during runtime.  The aim is to eventually run run an external application that is able to manipulate running processes for optimisation purposes.  So far, I have gone down the route of using GDB to manipulate memory, by following this tutorial: </p>
  
  <p><a href="http://www.codeproject.com/Articles/33340/Code-Injection-into-Running-Linux-Application?fid=1534990&amp;df=90&amp;mpp=10&amp;sort=Position&amp;spc=Relaxed&amp;tid=4678205" rel="noreferrer">http://www.codeproject.com/Articles/33340/Code-Injection-into-Running-Linux-Application?fid=1534990&amp;df=90&amp;mpp=10&amp;sort=Position&amp;spc=Relaxed&amp;tid=4678205</a></p>
  
  <p>However, it is fairly dated now and i cant seem to get it working on a 64-bit architecture... I would appreciate any advice on this topic.  Cheers</p>