summaryrefslogblamecommitdiffstats
path: root/src/patcher.cpp
blob: 5fdbdf8b2161269c6b8357d42dd7b482764c0caa (plain) (tree)





















                                          
#include "common.h"
#include "patcher.h"

StaticPatcher *StaticPatcher::ms_head;

StaticPatcher::StaticPatcher(Patcher func)
 : m_func(func)
{
	m_next = ms_head;
	ms_head = this;
}

void
StaticPatcher::Apply()
{
	StaticPatcher *current = ms_head;
	while(current){
		current->Run();
		current = current->m_next;
	}
	ms_head = nil;
}