Want everyone on your software team to learn this? Get completion tracking and compliance reporting with Hacksplaining for Teams. Free 14-day trial.
One common approach is to fill as much of the program's memory space as possible with no-op ("no operation") instructions then place the injected code at the end. If the progam's execution context lands on any of the no-op codes, it will skip to the next no-op, then the next, and so on, until it finally executes the injected code.